mirror of
https://github.com/nuxt/nuxt.git
synced 2025-01-30 15:22:39 +00:00
Allow override NODE_ENV with env config.
This allows debugging SSR hydration problems easier in production. (#727 and #574)
This commit is contained in:
parent
c6556c6b8b
commit
054df82200
@ -46,7 +46,7 @@ export default function () {
|
||||
config.plugins = (config.plugins || []).concat([
|
||||
// Strip comments in Vue code
|
||||
new webpack.DefinePlugin(Object.assign(env, {
|
||||
'process.env.NODE_ENV': JSON.stringify(this.dev ? 'development' : 'production'),
|
||||
'process.env.NODE_ENV': JSON.stringify(env.NODE_ENV || (this.dev ? 'development' : 'production')),
|
||||
'process.BROWSER_BUILD': true,
|
||||
'process.SERVER_BUILD': false,
|
||||
'process.browser': true,
|
||||
|
Loading…
Reference in New Issue
Block a user