fix: duplicate setState on vue flow mount

# What's changed?

* Set props on watcher initialization, so we avoid duplicate setStates (from composable and watchers)
* Fix pausable watchers not starting up
* Flush watchers on post
This commit is contained in:
Braks
2022-04-21 10:47:53 +02:00
parent 8b3acda42e
commit 12e42e6871
3 changed files with 188 additions and 121 deletions
+2
View File
@@ -38,6 +38,8 @@ const isDef = <T>(val: T): val is NonNullable<T> => typeof val !== 'undefined'
const defaultState = (): State => ({
nodes: [],
edges: [],
nodeTypes: {},
edgeTypes: {},
initialized: false,
instance: null,