Working with NPM and Packages

We already used NPM, the Node Package Manager, in order to install a single package and its dependencies for the example project in The Node Beginner Book.

However, there is much more to NPM, and a more thorough introduction is in order.

The most useful thing that NPM does isn't installing packages. This could be done manually with slightly more hassle. What's really useful about NPM is that it handles package dependencies. A lot of packages that we need for our own project need other packages themselves. Have a look at h t t p s ://n p m j s . o r g /p a c k a g e /r e q u e s t, for example. It's the overview page for the NPM package request. According to its description, it provides a simplified HTTP request ...

Get The Node Craftsman Book now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.