diff --git a/docs/src/demos/Examples/ExportHtmlOrJson/index.spec.js b/docs/src/demos/Examples/ExportHtmlOrJson/index.spec.js index 482e30c2..4e96f2a4 100644 --- a/docs/src/demos/Examples/ExportHtmlOrJson/index.spec.js +++ b/docs/src/demos/Examples/ExportHtmlOrJson/index.spec.js @@ -5,7 +5,7 @@ context('/examples/export-html-or-json', () => { beforeEach(() => { cy.get('.ProseMirror').then(([{ editor }]) => { - editor.setContent('
Example Text
') + editor.commands.setContent('Example Text
') }) }) diff --git a/docs/src/demos/Examples/ExportHtmlOrJson/index.vue b/docs/src/demos/Examples/ExportHtmlOrJson/index.vue index 98cbe592..d5a53f87 100644 --- a/docs/src/demos/Examples/ExportHtmlOrJson/index.vue +++ b/docs/src/demos/Examples/ExportHtmlOrJson/index.vue @@ -69,7 +69,7 @@ export default { methods: { setContent() { // You can pass a JSON document … - this.editor.setContent({ + this.editor.commands.setContent({ type: 'document', content: [{ type: 'paragraph', @@ -86,12 +86,15 @@ export default { // this.editor.setContent('This is some inserted text. 👋
') // It’s likely that you’d like to focus the Editor after most commands. - this.editor.focus() + this.editor.commands.focus() }, clearContent() { - this.editor.clearContent(true) - this.editor.focus() + this.editor + .chain() + .clearContent(true) + .focus() + .run() }, }, diff --git a/docs/src/demos/Examples/Links/index.vue b/docs/src/demos/Examples/Links/index.vue index b67aea84..e3240fc7 100644 --- a/docs/src/demos/Examples/Links/index.vue +++ b/docs/src/demos/Examples/Links/index.vue @@ -11,7 +11,7 @@