list all globally installed modules with one command in ubuntu

Muhsin Keloth picture Muhsin Keloth · Nov 14, 2016 · Viewed 31.2k times · Source

I'm working on ubuntu 14.04, Is there any way to print all global modules (installed using npm) to the command line. How can I do this?

Answer

Muhsin Keloth picture Muhsin Keloth · Nov 16, 2016

The below command will list all your globally installed modules on Linux, Mac, and Windows.

npm ls -g --depth 0