What does "npm install -g" do?
node.js, npm
Solution
You are not required to install Less globally.
Installing it locally means the module will be available only for a specific project (the directory you were in when you ran `npm install`), as it installs to the local `node_modules` folder.
A global install will instead put the module into your global package folder (OS dependent), and allows you to run the included executable commands from anywhere. Note that by default you can only require local packages in your code.
See the node.js docs for more info on global vs local packages.
Generally speaking, you should install most modules locally, unless they provide a CLI command that you want to use anywhere.
In the end, I suggest you install less globally, as less provides an executable command that you will likely need in different projects. This is also what the Less docs recommend.
Problem
I am trying to install Less from NPM by running `npm install -g less` in the command line. I checked the docs for the install command: In global mode (ie, with -g or --global appended to the command), it installs the current package context (ie, the current working directory) as a global package. What does it mean by "global package"?