nodemon not working: -bash: nodemon: command not found nodemon not working: -bash: nodemon: command not found express express

nodemon not working: -bash: nodemon: command not found


I tried the following, and none worked:

npm uninstall nodemonsudo npm uninstall -g nodemon

What did work was:

sudo npm install -g --force nodemon


If you want to run it locally instead of globally, you can run it from your node_modules:

npx nodemon


From you own project.

npx nodemon [your-app.js]

With a local installation, nodemon will not be available in your system path. Instead, the local installation of nodemon can be run by calling it from within an npm script (such as npm start) or using npx nodemon.

OR

Create a simple symbolik link

ln -s /Users/YourUsername/.npm-global/bin/nodemon /usr/local/bin

ln -s [from: where is you install 'nodemon'] [to: folder where are general module for node]

node : v12.1.0

npm : 6.9.0