鍍金池/ 問答/C++  HTML/ vue項目,webpack打包出來的index.html為什么公用代碼mainf

vue項目,webpack打包出來的index.html為什么公用代碼mainfest沒有添加進去

vue項目打包后,運行報:webpackjsonp is not defined
clipboard.png

手動添加之后才生效

clipboard.png

webpack.prod.conf.js

new HtmlWebpackPlugin({
      filename: process.env.NODE_ENV === 'testing'
        ? 'index.html'
        : config.build.index,
      template: 'index.html',
      inject: true,
      minify: {
        removeComments: true,
        collapseWhitespace: true,
        removeAttributeQuotes: true
      },
      chunks:['mainfest', 'vendor', 'app'],
      chunksSortMode: 'dependency'
    }),

請問需要修改哪的配置?

回答
編輯回答
忠妾
chunks: ['manifest', 'vendor', 'app']

而不是mainfest

2017年4月18日 23:44