docs: code errors in "Updating Node Data" (#1900)

fix(docs): Example of fixing code errors in "Updating Node Data"
This commit is contained in:
J
2025-07-19 04:57:05 +08:00
committed by GitHub
parent 447b2b05fd
commit b5c4c0e3f5

View File

@@ -342,8 +342,8 @@ import { useVueFlow } from '@vue-flow/core'
const instance = useVueFlow()
// use the `updateNodeData` method to update the data of an edge
instance.updateNodeData(edgeId, { hello: 'mona' })
// use the `updateNodeData` method to update the data of an node
instance.updateNodeData(nodeId, { hello: 'mona' })
// find the node in the state by its id
const node = instance.findNode(nodeId)