fix(core): correct id access in useVueFlow (#1483)

* fix(core): correct id access in `useVueFlow`

* chore(changeset): add
This commit is contained in:
Braks
2024-06-18 12:49:20 +02:00
parent aab43d5247
commit e2ce2053e4
2 changed files with 7 additions and 2 deletions
+2 -2
View File
@@ -30,9 +30,9 @@ export function useVueFlow(idOrOpts?: any): VueFlowStore {
const isOptsObj = typeof idOrOpts === 'object'
const options = isOptsObj ? idOrOpts : undefined
const options = isOptsObj ? idOrOpts : { id: idOrOpts }
const id = options?.id ?? idOrOpts
const id = options.id
const vueFlowId = scope?.vueFlowId || id
let vueFlow: Injection