tinyMCE是一款非常优秀的在线编辑器。在默认配置下,当我们粘贴word/html时,word/html里的样式也会一起粘贴进来,有没办法在粘贴时只粘贴文本文字呢?
在初始化tinyMCE我们加上如下配置就能做到:
plugins: 'paste',
...
paste_auto_cleanup_on_paste : true,
paste_remove_styles: true,
paste_remove_styles_if_webkit: true,
paste_strip_class_attributes: true,
转载于:https://blog.youkuaiyun.com/mypcstyle/article/details/37510767