NPM&SemanticVersioning(Semver)

1. NPM:

The NODE package manager.

2. Package management system:

Software that automates installing and updating packages.

Deals with what version you have or need, and manages dependencies.

3. Semantic versioning(Semver)

Versioning: Specifying what version of a set of code this is ...

...so others can track if a new version has come out. This allows to watch for new features, or to watch for 'breaking changes'.

The word 'semantic' implies that something conveys meaning.

4. MAJOR.MINOR.PATCH

eg. 1.7.2

eg1: change the patch num if some bugs were fixed. Your code will work fine.

eg2: change the minor num if some new features were added. Your code will work fine. backward compatible

eg3: change the major num if some big changes. Your code will break(maybe).

5. npm registry & package.json

package.json is used by npm to download the dependency package

nodemon: reload, automatically

Nodemon is a utility that will monitor for any changes in your source and automatically restart your server. Perfect for development. Install it using npm.

Just usenodemoninstead ofnodeto run your code, and now your process will automatically restart when your code changes.

https://nodemon.io/

Features:

Automatic restarting of application.

  • Detects default file extension to monitor.

  • Default support for node & coffeescript, but easy to run any executable (such as python, make, etc).

  • Ignoring specific files or directories.

  • Watch specific directories.

  • Works with server applications or one time run utilities and REPLs.

  • Requirable in node apps.

  • Open source and available on github.

Last updated

Was this helpful?