wangeditor

在vue项目里使用后,文本编辑器里按键盘里的删除按键无效,其他键都没事,键盘没问题

问题描述

问题出现的环境背景及自己尝试过哪些方法

vue 项目,富文本编辑器写在一个dialog组件里,就删除键无效

相关代码

this.editor = new E(this.$refs.editorElem);
      this.editor.customConfig.onchange = html => {
        this.editorContent = html;
        this.catchData(this.editorContent);
      };
      this.editor.customConfig.menus = [
        "head", // 标题
        "bold", // 粗体
        "fontSize", // 字号
        "fontName", // 字体
        "italic", // 斜体
        "underline", // 下划线
        "strikeThrough", // 删除线
        "foreColor", // 文字颜色
        "backColor", // 背景颜色
        "link", // 插入链接
        "list", // 列表
        "justify", // 对齐方式
        "quote", // 引用
        "emoticon", // 表情
        "image", // 插入图片
        "table", // 表格
        "video", // 插入视频
        "code", // 插入代码
        "undo", // 撤销
        "redo" // 重复
      ];
      this.editor.create();

你期待的结果是什么?实际看到的错误信息又是什么?

想知道什么原因和如何解决

阅读 1.3k
撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题