1. Webpack packing compression ES6 js,. Vue Error:
ERROR in Js/test.js from uglifyjsunexpected token punc? (?, expected Punc?:?) [js/test.js:1374,5]
This problem is usually because JS uses the ES6 notation, UGLIFYJS does not support compression error.
Workaround:
1 See if there is a conversion using Babel. Open Webpack.base.conf.js
{ test:/\.js$/, loader: ' Babel-loader ', include: [Resolve (' src '), resolve (' test '), resolve (' public ')] },
Check to see if your code is included in the include.
2 See if the converted version is es2015
Configure Babel, put the configuration in the file ". BABELRC"
{"Presets": ["es2015"]}
2. Cannot read property ' install ' of undefinedAt Function.Vue.use (vue.esm.js?65d7:4343)This error occurs because vue.use a non-existent component. There is no install method. So to troubleshoot which plug-in is not import.
Webpack Vue-cli Frequently Asked questions summary