thanhtunguet / grapesjs-react

A React wrapper for GrapesJS library
https://thanhtunguet.github.io/grapesjs-react
194 stars 58 forks source link

Export the editor data as HTML file #52

Open canaryGrapher opened 3 years ago

canaryGrapher commented 3 years ago

How do I export the various CSS and the HTML objects in the editor state into one single HTML file?

thanhtunguet commented 3 years ago

How do I export the various CSS and the HTML objects in the editor state into one single HTML file?

I don't know if GrapesJS supports this feature or not. Please refer to its documentation for more details. You can save the editor to component state by using onInit function. Then access editor's methods and properties to achieve your purpose.