Skip to content

Instantly share code, notes, and snippets.

@naganowl
Created May 25, 2018 22:26
Show Gist options
  • Save naganowl/6ce830db30e6566bdbce9696ca3c5199 to your computer and use it in GitHub Desktop.
Save naganowl/6ce830db30e6566bdbce9696ca3c5199 to your computer and use it in GitHub Desktop.
Differences b/w Git vs. npm tags

There is a difference b/w a prerelease tag associated to a package version (https://docs.npmjs.com/misc/semver#prerelease-tags) and a package's distribution tag upon publish (https://docs.npmjs.com/cli/dist-tag#purpose).

Thus, given the URL schemas dictated by https://docs.npmjs.com/files/package.json#git-urls-as-dependencies it be possible to publish an npm package with both a prerelease tag on a version and a distribution tag to give two options for targetting within a library

The RFC behind the new semver notation specifies just a prerelease tag. It be worthwhile to publish some sort of distribbution tag to avoid clobbering the default latest tag that npm uses

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment