OSD600 – Publishing my-ssg To NPM

1. Lab10 requirement

After a long time updating my-sgg with new features, this time is an appropriate time to provide a release that allows users to install and use the tool easier.

Since the tool is written in NodeJS, I will make use of n…


This content originally appeared on DEV Community and was authored by Vivian

1. Lab10 requirement

After a long time updating my-sgg with new features, this time is an appropriate time to provide a release that allows users to install and use the tool easier.

Since the tool is written in NodeJS, I will make use of npm to share the tool.

2. Publishing process

In order to publish a package to npm, I need to create an npm account first. If not, an error code 404 will be appeared.
Image description
Next, I verified the email to authenticate the account. After having an authenticated account, I run npm login command then provided username, password and email to sign in the npm account.

When I logged in successfully, a message will be displayed to announce.
Image description

Finally, I run npm publish command to publish the package to npm.

After making sure that the package is available in npm I asked my friend to test the tool. Instead of telling her how to install and use the package, I recommended her to read through the README.md file first.
With the instruction on README.md she succeeded in installing the package. On her machine, she tested all the provided features and they all worked as expected.

3. Overall

This is an interesting lab, I have a chance to learn new knowledge about npm package since I never published a package before. Also, this is a good way to share my work with others.

All in all, thank you for reading the post.

Happy coding!


This content originally appeared on DEV Community and was authored by Vivian


Print Share Comment Cite Upload Translate Updates
APA

Vivian | Sciencx (2021-11-27T06:39:02+00:00) OSD600 – Publishing my-ssg To NPM. Retrieved from https://www.scien.cx/2021/11/27/osd600-publishing-my-ssg-to-npm/

MLA
" » OSD600 – Publishing my-ssg To NPM." Vivian | Sciencx - Saturday November 27, 2021, https://www.scien.cx/2021/11/27/osd600-publishing-my-ssg-to-npm/
HARVARD
Vivian | Sciencx Saturday November 27, 2021 » OSD600 – Publishing my-ssg To NPM., viewed ,<https://www.scien.cx/2021/11/27/osd600-publishing-my-ssg-to-npm/>
VANCOUVER
Vivian | Sciencx - » OSD600 – Publishing my-ssg To NPM. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2021/11/27/osd600-publishing-my-ssg-to-npm/
CHICAGO
" » OSD600 – Publishing my-ssg To NPM." Vivian | Sciencx - Accessed . https://www.scien.cx/2021/11/27/osd600-publishing-my-ssg-to-npm/
IEEE
" » OSD600 – Publishing my-ssg To NPM." Vivian | Sciencx [Online]. Available: https://www.scien.cx/2021/11/27/osd600-publishing-my-ssg-to-npm/. [Accessed: ]
rf:citation
» OSD600 – Publishing my-ssg To NPM | Vivian | Sciencx | https://www.scien.cx/2021/11/27/osd600-publishing-my-ssg-to-npm/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.