Build error when NODE_ENV=production #18663
-
Hello, I have scaffolded a tiny app and hosted it on Render.com. It wasn't expected since according to the documentation ERROR:
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
If you set Vite sets |
Beta Was this translation helpful? Give feedback.
If you set
NODE_ENV=production
beforenpm install
, npm does not installdevDependencies
.https://docs.npmjs.com/cli/v8/commands/npm-install#:~:text=With%20the%20%2D%2Dproduction,production%3Dfalse.
Vite sets
NODE_ENV=production
in build whenNODE_ENV
is not set, so probably you don't need to set it manually.