How to Publish an npx Command to Improve productivity?

Jen-Hsuan Hsieh (Sean)
A Layman
Published in
4 min readDec 18, 2020

--

Introduction

Blog posting is kind of my knowledge base. I can review and apply knowledge from those posts to my new projects.

Building tools is another efficient way to create a new project without recalls or a few manual works. To integrate the knowledge, I create an npx tool to create a new project with Next.js, Redux, and Styled Components with default folders and files.

This topic is the note that now to create and publish a new npx tool to npm. There are two sections I will mention.

  • Steps to push a new npx command
  • Other useful commands to manage npm packages
  • NPM package semantic versioning

Steps to push a new npx command

The target of the below steps is to create and publish an interactive npx command.

1. Create a new npm project

Type the following command in the terminal.

--

--

Jen-Hsuan Hsieh (Sean)
A Layman

Frontend Developer🚀 Angular • React • Nest • Electron • Micro-frontend • Monorepo Architecture • https://daily-learning.herokuapp.com/