fix(flow): check for scope before providing store

This commit is contained in:
Braks
2022-04-03 12:36:14 +02:00
parent c560a312b8
commit 3d66775678
2 changed files with 5 additions and 3 deletions

View File

@@ -40,8 +40,9 @@ export default defineComponent({
onNodeDragStop(e: FlowEvents['nodeDragStop']) {
console.log('drag stop', e)
},
onPaneReady({ fitView }: FlowEvents['paneReady']) {
fitView({ padding: 0.1 })
onPaneReady(instance: FlowEvents['paneReady']) {
instance.fitView()
this.instance = instance
},
onConnect(params: FlowEvents['connect']) {
addEdge(params, this.elements)