This content originally appeared on 2ality – JavaScript and more and was authored by Dr. Axel Rauschmayer
In this blog post, we learn how to implement shell scripts via Node.js ESM modules. There are two common ways of doing so:
- We can write a stand-alone script and install it ourselves.
- We can put our script in an npm package and use a package manager to install it. That also gives us the option to publish the package to the npm registry so that others can install it, too.
This content originally appeared on 2ality – JavaScript and more and was authored by Dr. Axel Rauschmayer

Dr. Axel Rauschmayer | Sciencx (2022-07-28T00:00:00+00:00) Node.js: creating ESM-based shell scripts for Unix and Windows. Retrieved from https://www.scien.cx/2022/07/28/node-js-creating-esm-based-shell-scripts-for-unix-and-windows/
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.