ensures NODE_ENV is set properly within client

This commit is contained in:
James
2020-10-02 21:36:02 -04:00
parent 3b82d1ccba
commit c6105d9ed3
3 changed files with 3 additions and 7 deletions

View File

@@ -94,9 +94,7 @@ module.exports = (config) => {
new webpack.DefinePlugin(Object.entries(config.publicENV).reduce((values, [key, val]) => ({
...values,
[`process.env.${key}`]: `'${val}'`,
}), {
'process.env.NODE_ENV': `'${process.env.NODE_ENV}'`,
})),
}), {})),
new HtmlWebpackPlugin({
template: config.admin && config.admin.indexHTML
? path.join(config.paths.configDir, config.admin.indexHTML)