send only json steps

This commit is contained in:
Philipp Kühn
2019-05-05 21:47:52 +02:00
parent 03cb2d4c75
commit 76dca53d80
3 changed files with 26 additions and 2 deletions

View File

@@ -342,6 +342,13 @@ export default class Editor extends Emitter {
this.view.dom.blur()
}
getSchemaJSON() {
return JSON.parse(JSON.stringify({
nodes: this.extensions.nodes,
marks: this.extensions.marks,
}))
}
getHTML() {
const div = document.createElement('div')
const fragment = DOMSerializer