easy-argument-parser

Parse command line arguments into a Javascript object

Usage no npm install needed!

<script type="module">
  import easyArgumentParser from 'https://cdn.skypack.dev/easy-argument-parser';
</script>

README

easy-argument-parser

Simple way read command-line arguments in your project.

installation

npm install easy-argument-parser --save

Usage

In your app:

//my-app.js
var args = require('easy-argument-parser');

console.log(args);

Then you can run your file like this:

node my-app.js --option1 --option2=10
> $ {option1: true, option2: 10}