Open yinxuejing123 opened 5 months ago
在Vue页面全局引入注册 <vue-ueditor-wrap v-model="editorContent" :config="editorConfig" :editor-id="editorId" ref="ueditorWrap" class="u-editor" @ready="handleEditorReady"> 封装的组件 editorConfig: { // 访问 UEditor 静态资源的根路径,可参考 https://hc199421.gitee.io/vue-ueditor-wrap/#/faq UEDITOR_HOME_URL: "./../../static/public/UEditor/", // 服务端接口(这个地址是我为了方便各位体验文件上传功能搭建的临时接口,请勿在生产环境使用!!!) serverUrl: "", toolbars: [ [ 'source', '|', 'bold', 'italic', 'underline', 'strikethrough', // 'blockquote', '|', 'forecolor', 'backcolor', 'insertorderedlist', 'insertunorderedlist', '|', 'removeformat', 'formatmatch', 'pasteplain', '|', // 'undo', // 'redo', // '|', 'simpleupload', // 'insertimage', ], ], }, 配置项 <editor :editor-disabled="disabled" @editor-return="editorReturn" :editor-id="editorId" :content="formData.content" :is-show-gallery="false" :gallery-type="2" :dataid="''" v-if="showEditor"> 页面引入
在Vue页面全局引入注册 <vue-ueditor-wrap v-model="editorContent" :config="editorConfig" :editor-id="editorId" ref="ueditorWrap" class="u-editor" @ready="handleEditorReady"> 封装的组件 editorConfig: { // 访问 UEditor 静态资源的根路径,可参考 https://hc199421.gitee.io/vue-ueditor-wrap/#/faq UEDITOR_HOME_URL: "./../../static/public/UEditor/", // 服务端接口(这个地址是我为了方便各位体验文件上传功能搭建的临时接口,请勿在生产环境使用!!!) serverUrl: "", toolbars: [ [ 'source', '|', 'bold', 'italic', 'underline', 'strikethrough', // 'blockquote', '|', 'forecolor', 'backcolor', 'insertorderedlist', 'insertunorderedlist', '|', 'removeformat', 'formatmatch', 'pasteplain', '|', // 'undo', // 'redo', // '|', 'simpleupload', // 'insertimage', ], ], }, 配置项
<editor :editor-disabled="disabled" @editor-return="editorReturn" :editor-id="editorId" :content="formData.content" :is-show-gallery="false" :gallery-type="2" :dataid="''" v-if="showEditor"> 页面引入