Node: MacOS

Installing and working with Node, npm, nvm on MacOS

Install npm packages globally without sudo on macOS

These instructions work for Linux too.

Should I install npm or nvm?

Most node tutorials suggest installing node and then using the tool npm.

It’s probably a better idea to work with nvm if you are using your own computer, as that will allow you to maintain separate node environments for different projects.

This StackOverflow answer explains more:

Installing nvm


npm install wants root / sudo. What should I do?

See this StackOverflow answer: