gojs-react.当onModelChange发生时,我如何通过UI通过编程更改我所做的模型更



当我通过UI编辑图时,onModelChange事件发生。当我编辑图的模型通过代码(模型。设置(节点,可删除,false)), onModelChange事件发生

我想有一种方法来忽略第二种类型的更改。因为我是在处理第一种类型的更改时做的。我得到了递归

YouronModelChange处理程序应该设置skipsDiagramUpdate为true。这可以防止在GoJS模型已经知道的更改时调用处理程序。

https://gojs.net/latest/intro/react.html UsingWrapperComponentWithinApphttps://github.com/NorthwoodsSoftware/gojs-react-basic

最新更新