refactor(types)!: Remove ElementId type

Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
Braks
2021-12-20 19:29:52 +01:00
parent fe0eeaeae9
commit f00f34d84b
28 changed files with 99 additions and 150 deletions
+1 -2
View File
@@ -1,6 +1,5 @@
import { getSourceTargetNodes } from './edge'
import {
ElementId,
Node,
Edge,
Elements,
@@ -81,7 +80,7 @@ export const removeElements = (elementsToRemove: Elements, elements: Elements) =
return elements.filter((element) => !shouldRemove(element))
}
const getEdgeId = ({ source, sourceHandle, target, targetHandle }: Connection): ElementId =>
const getEdgeId = ({ source, sourceHandle, target, targetHandle }: Connection) =>
`vueflow__edge-${source}${sourceHandle}-${target}${targetHandle}`
const connectionExists = (edge: Edge, elements: Elements) => {