javascriptjqueryjointjsrappid

How to make a save workspace functionality in jointjs?


I am new to JointJS. My need to use JointJS library is to have a module in my project that a user can make flowcharts in his dashboard panel. I have implemented this example in my project. I want an option to save the workspace in this example. Please suggest if it is possible and how to do it.

Thanks


Solution

  • graph.toJSON / graph.fromJSON might help you out. Docs: https://resources.jointjs.com/docs/jointjs/v2.1/joint.html#dia.Graph.prototype.toJSON