Mid From PDF Node.js Node.js

How do you install a package globally vs locally?

Local Installation (default):

Installs the package into the node_modules folder of your current project.

npm install lodash

  • ✅ Used when the package is needed as part of your app's code.

Global Installation:

Installs the package system-wide, making it available in the command line anywhere.

npm install -g nodemon

  • ✅ Used for tools/CLI apps like nodemon, eslint, typescript, etc.

More from Node.js Tutorial

All questions for this course
Toolliyo Assistant
Ask about tutorials, ebooks, training, pricing, mentor services, and support. I use public site content only—not admin or internal tools.

care@toolliyo.com

Need callback? Share your details