ckeditor4-vue&UGLIFYJS

问题描述 投票:0回答:1

所以我已经很久没搞清楚了,当我尝试这样做时应该做哪些改变

npm运行构建

它出现以下错误

ERROR in static/js/vendor.ed03b8c8fa6b2d569140.js from UglifyJs
Unexpected token: name (i) [./~/ckeditor4-vue/dist/ckeditor.js:5,1974][static/js/vendor.ed03b8c8fa6b2d569140.js:51884,1934]

但是在本地时>

效果很好

enter image description here

我的[[editor.vue

] >><template> <div id="app"> <ckeditor v-model="editorData" :config="editorConfig"></ckeditor> </div> </template> <script> import CKEditor from "ckeditor4-vue"; export default { name: "app", components: { ckeditor: CKEditor.component }, data() { return { editorData: "<p>Content of the damn editor.</p>", // https://ckeditor.com/docs/ckeditor4/latest/api/CKEDITOR_config.html editorConfig: { extraPlugins: "language,font,image2", toolbar: "Bold", height: 300, allowedContent: true, uiColor: "#AADC6E", codeSnippet_theme: "school_book", filebrowserImageBrowseLinkUrl: "https://onedrive.live.com/?id=59FFBD6D7046F78D%21105&cid=59FFBD6D7046F78D", font_names: "Arial/Arial, Helvetica, sans-serif;" + "Times New Roman/Times New Roman, Times, serif;" + "Verdana", codeSnippet_languages: { javascript: "JavaScript", php: "PHP" } } }; } }; </script>

Webpack.prod.conf.js

webpackversion [email protected]

plugins: [ // http://vuejs.github.io/vue-loader/en/workflow/production.html new webpack.DefinePlugin({ "process.env": env }), new webpack.optimize.UglifyJsPlugin({ compress: { warnings: false }, sourceMap: true }),

所以我已经很久没搞清楚了,当我尝试npm run build时应该做什么改变,它在static / js / vendor.ed03b8c8fa6b2d569140 ...中给出了以下错误ERROR ...
] >

ckeditor ckeditor4.x
1个回答
© www.soinside.com 2019 - 2024. All rights reserved.