@flowgram.ai/document 0.3.3 → 0.3.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/esm/index.js CHANGED
@@ -1979,6 +1979,11 @@ var FlowDocument = class {
1979
1979
  * 导出数据,可以重载
1980
1980
  */
1981
1981
  toJSON() {
1982
+ if (this.disposed) {
1983
+ throw new Error(
1984
+ "The FlowDocument has been disposed and it is no longer possible to call toJSON."
1985
+ );
1986
+ }
1982
1987
  return {
1983
1988
  nodes: this.root.toJSON().blocks
1984
1989
  };