使用tinymce編輯器從word保持原格式複製粘貼的辦法

tinymce官方有一個插件叫powerpaste(官方收費),找到資源後,把他引入到plugins下,並在tinymce下的index文件中把他引入:html

initTinymce() {
        const _this = this
        window.tinymce.init({
          language: 'zh_CN',
          plugins: ['powerpaste', plugins],
          powerpaste_word_import: 'merge', // 參數能夠是propmt, merge, clear
          powerpaste_html_import: 'merge', // propmt, merge, clear
          powerpaste_allow_local_images: true,//容許帶圖片
        })
   }this

相關文章
相關標籤/搜索