Javascript Package - Local Package

About

A local package is a package installed locally into your project.

As opposed to global where your package is available on the whole system (computer)

Management

npm install will create the node_modules directory in the current directory (if one doesn't exist yet), and will download the package to that directory.

Install

  • Yarn
yarn add package
  • Npm
npm install package 

Dev Dependency

npm install --save-dev <package_name>
npm uninstall --save-dev <package_name>

See npm install doc

Location

The node_modules directory in the current directory.

Update

in the same directory as your package.json file.

npm update 

https://docs.npmjs.com/cli/update

Outdated

npm outdated

No output ! https://docs.npmjs.com/cli/outdated

Size

https://bundlephobia.com - https://github.com/pastelsky/bundlephobia





Discover More
CommonJs (NodeJs) - Require

The import functionality implementation of commonjs (and then node) is done via the require function require basically: reads a Javascript file (generally a CommonJs module but it may be any javascript...
Javascript Package

in Javascript. A Package is a distribution format that wraps: one or several Module. along side the package.json (called a manifest) which describes the package (its version, ...) npmpackage.json...



Share this page:
Follow us:
Task Runner