在webpack配置html文件打包时出现如下错误
原因:
我的webpack的版本用的5.0的版本,然后与html-webpack-plugin 插件不兼容
解决方法:
安装4.0及以上的wepback和对应的HtmlWebpackPlugin
npm install webpack@4.44.2 -g
npm i html-webpack-plugin -D
webpack:The ‘compilation‘ argument must be an instance of Compilation
最新推荐文章于 2024-04-29 04:53:26 发布