webpack.prod.config.js 706 B

123456789101112131415161718192021
  1. // This file is auto-generated from the corresponding file in /dev_mode
  2. const merge = require('webpack-merge').default;
  3. const config = require('./webpack.config');
  4. const LicenseWebpackPlugin = require('license-webpack-plugin')
  5. .LicenseWebpackPlugin;
  6. config[0] = merge(config[0], {
  7. mode: 'production',
  8. devtool: 'source-map',
  9. output: {
  10. // Add version argument when in production so the Jupyter server
  11. // allows caching of files (i.e., does not set the CacheControl header to no-cache to prevent caching static files)
  12. filename: '[name].[contenthash].js?v=[contenthash]'
  13. },
  14. optimization: {
  15. minimize: false
  16. },
  17. plugins: [new LicenseWebpackPlugin()]
  18. });
  19. module.exports = config;