text: // Important modules this config uses
  const path = require('path');
  const webpack = require('webpack');
  const HtmlWebpackPlugin = require('html-webpack-plugin');
  const config = require('../../config');
  
  module.exports = require('./webpack.base.babel')({
    // In production, we skip all hot-reloading stuff
    entry: [
      path.join(process.cwd(), 'app/app.js'),
    ],
  
    // Utilize long-term caching by adding content hashes (not compilation hashes) to compiled assets
    output: {
      filename: `./${config.mountPoint}/[name].[chunkhash].js`,
      chunkFilename: `./${config.mountPoint}/[name].[chunkhash].chunk.js`,
      path: config.output,
    },
  
    plugins: [
      new webpack.optimize.ModuleConcatenationPlugin(),
      new webpack.optimize.CommonsChunkPlugin({
        name: 'vendor',
        children: true,
        minChunks: 2,
        async: true,
      }),
  
      // Minify and optimize the index.html
      new HtmlWebpackPlugin({
        template: 'app/index.html',
        minify: {
          removeComments: true,
          collapseWhitespace: true,
          removeRedundantAttributes: true,
          useShortDoctype: true,
          removeEmptyAttributes: true,
          removeStyleLinkTypeAttributes: true,
          keepClosingSlash: true,
          minifyJS: true,
          minifyCSS: true,
          minifyURLs: true,
        },
        inject: true,
      }),
    ],
  
    performance: {
      assetFilter: (assetFilename) => !(/(\.map$)|(^(main\.|favicon\.))/.test(assetFilename)),
    },
  });
  