echo $NODE_ENV
gives me production
Package.json on OSX:
"scripts": {
"dev": "backpack dev",
"build": "NODE_ENV=production nuxt build && backpack build",
"start": "node build/main.js",
"generate": "nuxt generate",
"lint": "eslint --ext .js,.vue --ignore-path .gitignore .",
"precommit": "npm run lint"
}
npm run build runs with process.env.NODE_ENV set to development. npm run start runs with process.env.NODE_ENV set to development and rebuilds every time.
I have verified both of the above with console.log statements.
I am using Nuxt with Express.
I do not understand where my environment is getting set to development. I have nothing in my nuxt.config.js that sets this environment variable.
Any help would be appreciated.
<!--cmty--><!--cmty_prevent_hook--><div align="right"><sub><em>This question is available on <a href="https://nuxtjs.cmty.io">Nuxt.js</a> community (<a href="https://nuxtjs.cmty.io/nuxt/nuxt.js/issues/c652">#c652</a>)</em></sub></div>