127.0.0.1:8000 personal-website / master webpack / webpack.prod.js
master

Tree @master (Download .tar.gz)

webpack.prod.js @masterraw · history · blame

const TerserPlugin = require('terser-webpack-plugin');

module.exports = Object.assign(require('./config.js'), {
    mode: 'production',
    optimization: {
        minimizer: [
            new TerserPlugin({
                terserOptions: {
                    toplevel: true,
                    compress: {
                        drop_console: true
                    },
                    output: {
                        comments: false
                    }
                },
                cache: true,
                parallel: true
            })
        ]
    }
});