Member-only story

Package.json, Understanding it for your nodejs, reactjs, angularjs or any javascript app which use npm.

krishankant singhal
6 min readJan 12, 2020

--

If you have ever worked on any node js or react or any npm application, you might have encounter a file known as package.json. It is kind of manifest file for your application.

package.json file play same role as played by pom.xml In Maven projects.package.json follow the json syntax. We can define various properties as described below.

Properties breakdown
name
author
contributors
bugs
homepage
version
license
keywords
description
repository
main
private
scripts
dependencies
devDependencies
engines
browserslist

The file structure

Here’s an example package.json file:

{}

It’s empty! There are no fixed requirements of what should be in package.json file for an application. The only requirement is that it respects the JSON format.

This is another package.json:

{
"name": "test-project"
}

--

--

krishankant singhal
krishankant singhal

Written by krishankant singhal

Angular,Vuejs,Android,Java,Git developer. i am nerd who want to learn new technologies, goes in depth.

Responses (1)