Return to site

ANGULAR: What is npm and what is the need for Angular application?

· ngInterview,fullstack

NPM (Node Package manager 📦🧑‍💼) is the package manager which we are using for installing the dependencies which is required for the application.

In Angular, we have package.json file in which all the dependencies have added which we have installed.

When we need any new dependencies, we can simply install using below command 🖥️:

npm install --save .

It adds the installed package in node_modules folder and also, adds the dependencies in package.json file.


--save: Save installed packages to a package.json file as dependencies.

--save-dev: Package will appear in your devDependencies.

--save-g: 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.