aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/config
diff options
context:
space:
mode:
Diffstat (limited to 'client/config')
-rw-r--r--client/config/webpack.prod.js12
1 files changed, 12 insertions, 0 deletions
diff --git a/client/config/webpack.prod.js b/client/config/webpack.prod.js
index 51b8a8855..6d65fcb37 100644
--- a/client/config/webpack.prod.js
+++ b/client/config/webpack.prod.js
@@ -12,6 +12,7 @@ const commonConfig = require('./webpack.common.js') // the settings that are com
12const DefinePlugin = require('webpack/lib/DefinePlugin') 12const DefinePlugin = require('webpack/lib/DefinePlugin')
13const LoaderOptionsPlugin = require('webpack/lib/LoaderOptionsPlugin') 13const LoaderOptionsPlugin = require('webpack/lib/LoaderOptionsPlugin')
14const NormalModuleReplacementPlugin = require('webpack/lib/NormalModuleReplacementPlugin') 14const NormalModuleReplacementPlugin = require('webpack/lib/NormalModuleReplacementPlugin')
15const OptimizeJsPlugin = require('optimize-js-plugin')
15const UglifyJsPlugin = require('webpack/lib/optimize/UglifyJsPlugin') 16const UglifyJsPlugin = require('webpack/lib/optimize/UglifyJsPlugin')
16const WebpackMd5Hash = require('webpack-md5-hash') 17const WebpackMd5Hash = require('webpack-md5-hash')
17 18
@@ -99,6 +100,17 @@ module.exports = function (env) {
99 new WebpackMd5Hash(), 100 new WebpackMd5Hash(),
100 101
101 /** 102 /**
103 * Webpack plugin to optimize a JavaScript file for faster initial load
104 * by wrapping eagerly-invoked functions.
105 *
106 * See: https://github.com/vigneshshanmugam/optimize-js-plugin
107 */
108
109 new OptimizeJsPlugin({
110 sourceMap: false
111 }),
112
113 /**
102 * Plugin: DedupePlugin 114 * Plugin: DedupePlugin
103 * Description: Prevents the inclusion of duplicate code into your bundle 115 * Description: Prevents the inclusion of duplicate code into your bundle
104 * and instead applies a copy of the function at runtime. 116 * and instead applies a copy of the function at runtime.