diff --git a/open-isle-cli/src/components/CommentEditor.vue b/open-isle-cli/src/components/CommentEditor.vue index c0a9cb669..568ebbece 100644 --- a/open-isle-cli/src/components/CommentEditor.vue +++ b/open-isle-cli/src/components/CommentEditor.vue @@ -60,7 +60,10 @@ export default { 'link', 'image' ], - toolbarConfig: { pin: true } + toolbarConfig: { pin: true }, + after() { + vditorInstance.value = this + } }) }) diff --git a/open-isle-cli/src/components/PostEditor.vue b/open-isle-cli/src/components/PostEditor.vue index f18b17f50..3ac374de0 100644 --- a/open-isle-cli/src/components/PostEditor.vue +++ b/open-isle-cli/src/components/PostEditor.vue @@ -57,9 +57,11 @@ export default { cache: { enable: false }, input(value) { emit('update:modelValue', value) + }, + after() { + vditorInstance.value.setValue(props.modelValue) } }) - vditorInstance.value.setValue(props.modelValue) }) return {}