浏览代码

fix(tinymce): the editor reports an error under keep-alive #152

vben 4 年之前
父节点
当前提交
09c9f8a881
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      src/components/Tinymce/src/Editor.vue

+ 2 - 0
src/components/Tinymce/src/Editor.vue

@@ -92,6 +92,7 @@
         }
       );
       onMountedOrActivated(() => {
+        tinymceId.value = snowUuid('tiny-vue');
         nextTick(() => {
           init();
         });
@@ -152,6 +153,7 @@
       function bindModelHandlers(editor: any) {
         const modelEvents = attrs.modelEvents ? attrs.modelEvents : null;
         const normalizedEvents = Array.isArray(modelEvents) ? modelEvents.join(' ') : modelEvents;
+
         watch(
           () => props.modelValue,
           (val: string, prevVal: string) => {