How to Publish NPM Package to

2023/2/51 min read
bookmark this
Responsive image

npm init login to the

Type npm init and follow the steps to login into the

  npm init

npm publish to publish the package

There're few ways to publish NPM package, private, publish or publish to the organization. Here, we're publish as public, so type below command at the root folder of you node.js source code.

npm publish --access public

That's it.

If there's no error, your package should published to the, check the package under your account, should be able to find the package.