Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- module.exports = {
- mode: 'production',
- entry: {
- index: [
- 'babel-polyfill',
- './src/index.js',
- ],
- },
- output: {
- path: srcBuild,
- filename: '[name].js',
- chunkFilename: '[name].[chunkhash].js',
- libraryTarget: 'commonjs',
- libraryExport: 'default',
- },
- optimization: {
- noEmitOnErrors: true,
- minimizer: [
- new TerserPlugin({
- cache: true,
- parallel: true,
- sourceMap: true,
- terserOptions: {
- mangle: false,
- compress: {
- reduce_funcs: false,
- reduce_vars: false,
- keep_classnames: true,
- keep_fnames: true,
- keep_fargs: true,
- pure_getters: true,
- },
- },
- }),
- ],
- }
Add Comment
Please, Sign In to add comment