npm-publish
Publish a package to the npm registry. tldr-pages
On several platforms
Several platforms
Publish the current package to the default npm registry
npm publishIdentifyPublish a package from a specific directory
npm publish path/to/package_directoryIdentifyPublish a scoped package with public access
npm publish --access publicIdentifyPublish a scoped package with restricted (private) access
npm publish --access restrictedIdentifyPublish a package to a custom registry
npm publish --registry https://registry.npmjs.org/IdentifySimulate what would be published without uploading
npm publish --dry-runIdentifyPublish a package with a specific distribution tag (e.g., beta)
npm publish --tag betaIdentifyPublish with a one-time password for 2FA-enabled accounts
npm publish --otp one_time_passwordIdentify