July 2017
Intermediate to advanced
374 pages
8h
English
This file is, basically, metadata for your application, which contains the complete libraries /dependencies that need to be installed for your application. Another real-world advantage is that it makes your build reproducible, which means that it's way easier to share it with other developers. There are different ways in which you can create your customized package.json.
The following is the minimum information that needs to be provided in packages.json:
"Name" - lowercase.
"version" - in the form of x.x.x
For example:
{
"name": "my-twitter-package",
"version": "1.0.0"
}
In order to create the package.json template, you can use the following command:
$ npm init # in your workspace
It will ask for values such as name, ...