npm link
npm link <package.json.name>
npm login
npm logout
npm profile get
npm whoami
First Publish:
npm publish --access public
Subsequent Publishes:
npm publish
Publish only specific tag:
npm publish --tag develop
npm unpublish <package-name> -f
npm unpublish <package-name>@<version>
- Get your API Token from NPM
- Settings > Auth Token > Create New Token > Read & Publish
- Copy the token
- Add this API as as secret to your GitHub repo
- Settings > Secrets > New secret
- Name: NPM_TOKEN
- Value: <paste the token from step 1>
npm/next
- Pushing to npm/next branch will publish a new package with the 'next' tag
- Version name will be x.x.x-next.
master
- Pushing to master will publish a new package with the 'latest' tag
- Version name will be x.x.x
*x.x.x is obtained from package.json.version