vue項目build打包時遇到 Cannot read property 'compilation' of undefined 問題解決方法


TypeError: Cannot read property ‘compilation’ of undefined 錯誤。

(這里需要強調一下,安裝環境的使用一定要-save-dev或者是-save,否則欲哭無淚啊)

很明顯,這是node一些包的版本對應不上的問題。。。

查看package.jsonn里的webpack的版本號發現3.6.0 的版本,但是 optimize-css-assets-webpack-plugin 是2.0 的版本。

解決方法:

npm  install optimize-css-assets-webpack-plugin@3.2.0    將timize-css-assets-webpack-plugin版本替換掉


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



猜您在找 關於vue-cli3打包時遇到Cannot assign to read only property 'exports' of object '#'問題的解決方法。 webpack打包進行丑化壓縮遇到(TypeError Cannot read property 'compilation' of undefined)問題 Vue+elementUI開發中 Cannot read property 'resetFields' of undefined 問題解決以及原因分析 vue TypeError: Cannot read property 'length' of undefined 問題解決思路 vue-cli3 打包時使用‘babel-loader’遇到Cannot assign to read only property ‘exports’ of object '#'問題的解決方法。 Vue使用Typescript開發編譯時提示“ERROR in ./src/main.ts Module build failed: TypeError: Cannot read property 'afterCompile' of undefined”的解決方法 記一次前端問題解決歷程(Cannot read Property 'call' of undefined) 記一次前端問題解決歷程(Cannot read Property 'call' of undefined) [jQuery] Cannot read property ‘msie’ of undefined錯誤的解決方法 [jQuery] Cannot read property ‘msie’ of undefined錯誤的解決方法
 
粵ICP備18138465號   © 2018-2026 CODEPRJ.COM