In this tutorial, I will show you how to update Node Package Manager (NPM) to the latest version of this tool on macOS!
You can use the command npm -v to check the current version of NPM installed on your machine.
Currently, the NPM version that I am installing on my machine is:
To update to the latest version of NPM on macOS you can use the command:
1 |
sudo npm update -g |
You need to run as root user so that this command can override NPM files in the system.
My results when running this command are as follows:
Now you can check the version of NPM with the command npm -v above.
Mine, the result is as follows: