DEV Community

Dalitso Kasonde
Dalitso Kasonde

Posted on

Uninstall node js on MacOs big Sur

  1. Open your terminal
  2. Go to home directory
  3. Type cd usr
  4. Type cd local
  5. Type cd include
  6. Type ls
  7. Delete node directory by typing sudo rm -rf node
  8. Go back to local directory by typing cd ..
  9. Go to lib dirctory cd lib
  10. Delete node_modules folder, type sudo rm -rf node-modules
  11. Go to bin directory by typing cd .. and cd bin
  12. Type sudo rm -rf node

P>S : npm and npx folders can also be deleted inside the bin folder

Node.js is successfully uninstalled

Top comments (3)

Collapse
 
edwinm profile image
Edwin Martin

Line 3 is wrong. It should be "Type cd /usr".

Collapse
 
michael_teagle_d13709a4f2 profile image
Michael Teagle • Edited

Step above that says to go to home directory. But he could put "Type cd /" in the step to go to home directory.

Collapse
 
edwinm profile image
Edwin Martin

But / is not home directory, it's called root directory. ~ is the home directory.