Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 19 additions & 2 deletions app/webpack.prod.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
const merge = require('webpack-merge').default;
const config = require('./webpack.config');
const WPPlugin = require('@jupyterlab/builder').WPPlugin;
const TerserPlugin = require('terser-webpack-plugin');


config[0] = merge(config[0], {
mode: 'production',
Expand All @@ -16,8 +18,23 @@ config[0] = merge(config[0], {
filename: '[name].[contenthash].js?v=[contenthash]',
},
optimization: {
minimize: false,
},
minimize: true,
minimizer: [
new TerserPlugin({
parallel: true,
terserOptions: {
compress: false,
ecma: 6,
mangle: true,
output: {
beautify: false,
comments: false
},
safari10: true
}
})
]
},
plugins: [
new WPPlugin.JSONLicenseWebpackPlugin({
excludedPackageTest: (packageName) =>
Expand Down
Loading