Summary
To uninstall a global package, enter the following command in your terminal:
npm uninstall -g package-name
Details
To uninstall a global package, you can use the npm uninstall
command with a -g
flag. For example, if you wanted to uninstall the gatsby-cli
package, you would enter the following command in your terminal:
npm uninstall -g gatsby-cli
If the package was uninstalled successfully, you should see something similar to the following print out in your terminal:
removed 91 packages in 0.731s
To check that the package was uninstalled, enter the following command in your terminal to list all of your global packages:
npm list -g --depth 0
Exercises
There are no exercises for this lesson.