What is NPM? | Node JS

Sivamohan Ahagaash
3 min readApr 4, 2021

In this BLOG we talk about NPM one of the most important topic in the node.js series is NPM.” NPM” stands for node package manager but why do we need it first of all going to talk about node.js



now it is famous because it provides you a lot of different features one of them
is non-blocking i/o



NPM the package manager see what happens is as a developer when you build applications when you build websites or whatever type of application you build you need to use some external libraries you have to use some external dependencies so you can do everything from scratch right you can write the entire application by yourself but then if we are living in a world where you need to do things faster plus there are certain things right there right so example if you want to build if you want to find a way to connect with a database by yourself you can build an API which will help you to connect
your application with the database maybe you want to do some validations for the objects so let’s say you you have an object which has other properties and
you want to violate it now one way to do that is by building a module by yourself which will write at your object so those are ways right so you can build everything by yourself but then when you have a common task when you have a common problem since we have millions of developers and they are building the same thing which views you are doing so

why can’t we create a module which will be used by everyone so let’s say I’m solving a big problem so what we can do is we can convert that into small
problems right and then every problem or every solution will be one module and maybe what I can do is I can push this module to the repository so that
the entire world can use it right so when you build all the application will
be having some power and features right so you can put that in modules in the
same way when I talk about node.js node has a lot of in Bill modules one of that we have already seen is HTTP but what if you want to work with the file system we have for that what if you want to work with cryptography we are a module for that so no J’s has some inbuilt modules but what if you want extra modules what if you want to use someone else modules and
that’s where we have a concept of NPM which is node package manager now this concept is there in multiple languages when I work on Java we have libraries there we have dependencies so I can use that so we used to use maven there or Gradle to face that but they have a different approach now in terms of NPM it has millions of packages available
that’s right so last year when I saw the article if they have mentioned
that last year it was they have completed completed one million packages on NPM



about NPM so basically you can use all those packages so you can just fetch
them install on your machine and use them and you can also push your packages

--

--