gaosp
2024-01-13 b524dc50dedb0e6d8ae0a432ae2d436829da9319
build/webpack.prod.conf.js
@@ -29,7 +29,8 @@
  output: {
    path: config.build.assetsRoot,
    filename: utils.assetsPath('js/[name].[chunkhash].js'),
    chunkFilename: utils.assetsPath('js/[id].[chunkhash].js')
    chunkFilename: utils.assetsPath('js/[id].[chunkhash].js'),
    publicPath: './'
  },
  plugins: [
    // http://vuejs.github.io/vue-loader/en/workflow/production.html
@@ -67,8 +68,26 @@
      filename: config.build.index,
      template: 'index.html',
      inject: true,
      favicon: resolve('favicon.ico'),
      // favicon: resolve('favicon.ico'),
      title: 'mdc-portal',
      chunks: ['manifest', 'vendor', 'app'],
      minify: {
        removeComments: true,
        collapseWhitespace: true,
        removeAttributeQuotes: true
        // more options:
        // https://github.com/kangax/html-minifier#options-quick-reference
      },
      // necessary to consistently work with multiple chunks via CommonsChunkPlugin
      chunksSortMode: 'dependency'
    }),
    new HtmlWebpackPlugin({
      filename: config.build.test,
      template: 'index.html',
      inject: true,
      // favicon: resolve('favicon.ico'),
      title: 'mdc-portal',
      chunks: ['manifest', 'vendor', 'test'],
      minify: {
        removeComments: true,
        collapseWhitespace: true,