Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
name: 'manifest',
filename: 'manifest.js',
minChunks: Infinity,
}),
new ContextReplacementPlugin(/brace[\\\/]mode$/, /^\.\/(javascript|html|python|ruby|golang|swift|php|django|json|css|text)$/),
new ContextReplacementPlugin(/brace[\\\/]theme$/, /^\.\/(tomorrow)$/),
new ContextReplacementPlugin(/moment[\\\/]locale$/, /^\.\/(en-uk|en-us|en-au)$/),
new CompressionPlugin({
asset: "[path].gz[query]",
algorithm: "gzip",
test: /\.js$|\.css$/,
threshold: 10240,
minRatio: 0.8
})
]),
env.deploy && new S3Plugin(getS3Config(env))
]),
resolve: {
extensions: ['.js', '.jsx']
},
externals: {
'analyticsjs': 'window.analytics',
'stripejs': 'Stripe'
},
stats: 'errors-only',
devServer: {
stats: 'errors-only'
}
};
if (env.debug) {
console.log(config);