Answer the question
In order to leave comments, you need to log in
Why can't node.js find plugins when run from bat file?
There is a batch file:
set NODE_PATH="."
set NODE_ENV="development"
node --use_strict C:\Users\uuui\js\bin\server.js
PAUSE
Answer the question
In order to leave comments, you need to log in
I think that the node sees the variables, most likely it changes the current directory and "." already looking somewhere else. Write the full path to NODE_PATH.
You can add a module with js to the system environment variable. Then it should work without unnecessary paths and errors.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question