From 111b9cab2efa0240538f8aa3b8325b8c861ddec3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philipp=20Ku=CC=88hn?= Date: Tue, 11 Sep 2018 09:18:38 +0200 Subject: [PATCH] refactoring --- packages/tiptap/src/utils/ComponentView.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/tiptap/src/utils/ComponentView.js b/packages/tiptap/src/utils/ComponentView.js index f54b690b..0d058f47 100644 --- a/packages/tiptap/src/utils/ComponentView.js +++ b/packages/tiptap/src/utils/ComponentView.js @@ -16,12 +16,12 @@ export default class ComponentView { this.editable = editable this.dom = this.createDOM() - this.contentDOM = this._vm.$refs.content + this.contentDOM = this.vm.$refs.content } createDOM() { const Component = Vue.extend(this.component) - this._vm = new Component({ + this.vm = new Component({ propsData: { node: this.node, view: this.view, @@ -32,7 +32,7 @@ export default class ComponentView { updateContent: content => this.updateContent(content), }, }).$mount() - return this._vm.$el + return this.vm.$el } updateAttrs(attrs) { @@ -75,12 +75,12 @@ export default class ComponentView { this.node = node this.decorations = decorations - this._vm._props.node = node - this._vm._props.decorations = decorations + this.vm._props.node = node + this.vm._props.decorations = decorations return true } destroy() { - this._vm.$destroy() + this.vm.$destroy() } }