Reduce production built size

This commit is contained in:
uwap 2018-02-14 06:23:48 +01:00
parent a96fa1622b
commit f4d1cb7e1e
13 changed files with 56 additions and 38 deletions

View file

@ -12,7 +12,10 @@ const preBuildScripts = process.env.NO_FLOW == undefined ?
module.exports = {
resolve: {
modules: [path.resolve(__dirname, "src"), "node_modules"],
extensions: ['.js', '.jsx']
extensions: ['.js', '.jsx'],
alias: {
'lodash': 'lodash-es'
}
},
output: {
path: path.resolve(__dirname, 'dist'),
@ -30,6 +33,6 @@ module.exports = {
title: 'Space Map',
template: 'index.ejs'
}),
new ExtractTextPlugin("styles.css")
new ExtractTextPlugin("styles.css"),
]
};