Assertion on onMove function on reactflow
This commit is contained in:
parent
33d6fb8081
commit
db990f2472
1 changed files with 5 additions and 4 deletions
|
|
@ -371,10 +371,11 @@ export default function Page({ flow }: { flow: FlowType }) {
|
||||||
<ReactFlow
|
<ReactFlow
|
||||||
nodes={nodes}
|
nodes={nodes}
|
||||||
onMove={() => {
|
onMove={() => {
|
||||||
updateFlow({
|
if (reactFlowInstance)
|
||||||
...flow,
|
updateFlow({
|
||||||
data: reactFlowInstance.toObject(),
|
...flow,
|
||||||
});
|
data: reactFlowInstance.toObject(),
|
||||||
|
});
|
||||||
}}
|
}}
|
||||||
edges={edges}
|
edges={edges}
|
||||||
onPaneClick={() => {
|
onPaneClick={() => {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue