Oleg  Baranovsky
Oleg Baranovsky

Reputation: 389

Can't set node.js env

I'm using windows 7. I try to use SET NODE_ENV="development" command from cmd but this won't help. Also in npm in scripts I use NODE_ENV=development node app.js. But env still undefined.

Upvotes: 1

Views: 1206

Answers (1)

Oleg  Baranovsky
Oleg Baranovsky

Reputation: 389

Solution:

"scripts": {
    "start": "set NODE_ENV=development&& node app.js" 
}

Upvotes: 2

Related Questions