</>PackageGraphPackageGraph

yargs-parser

npmv22.0.0

the mighty option parser used by yargs

Adopt with care

yargs-parser is usable, with caveats. Last published 471 days ago.

  • AAdoption: grade A, Excellent.

    178.8M downloads per week and 2 known dependents.

  • CMaintenance: grade C, Fair — worth a look.

    Last published 471 days ago.

  • AWeight: grade A, Excellent.

    Zero runtime dependencies, about 84 KB installed.

  • ASupply chain: grade A, Excellent.

    No install scripts, 3 maintainers, and a contained dependency surface.

  • ALicense: grade A, Excellent.

    ISC — permissive, with no copyleft found in the dependency tree.

Grades are computed deterministically from registry metadata collected by PackageGraph — downloads, dependents, publish dates, the resolved dependency tree, maintainer count, and declared licenses. No third-party scores are used.

Install cost

What you actually take on by adding yargs-parser to a project.

0
Direct dependencies

Runtime packages this one declares itself.

0
Total installed

Distinct packages in the full runtime tree, deduplicated the way a package manager would.

84 KB
Install size

Unpacked size of this package plus its entire runtime tree.

Tree depth

Longest resolved dependency chain below this package.

Compatibility

Node.js
node ^20.19.0 || ^22.12.0 || >=23
Module format
ESM + CommonJS
TypeScript
No bundled types
Install scripts
None

Quick start

A usage example from the yargs-parser README.

const argv = require('yargs-parser')(process.argv.slice(2))
console.log(argv)

yargs-parser vs the alternatives

Packages solving a similar problem in the npm ecosystem, compared on the signals that drive an adoption decision.

PackageWeekly downloadsDependentsLicenseLast release
yargs-parserthis page178.8M2ISC1 year ago
yargs012MIT1 day ago
commander451.1M11MIT1 day ago
dashdash01MIT1 day ago
meow36.7M1MIT1 day ago
has-flag166.9M1MIT1 day ago

Dependencies

Declared by yargs-parser v22.0.0. Runtime dependencies are installed with the package; dev dependencies are not.

Dev (18)

@babel/eslint-parser ^7.27.1@babel/preset-typescript ^7.27.1@types/chai ^5.2.1@types/mocha ^10.0.10@types/node ^22.15.3@typescript-eslint/eslint-plugin ^8.29.1@typescript-eslint/parser ^8.31.1c8 ^10.1.3chai ^5.2.0cross-env ^7.0.2eslint ^8.57.1gts ^5.3.1mocha ^11.1.0puppeteer ^24.6.1rimraf ^6.0.1serve ^14.0.0start-server-and-test ^2.0.11typescript ^5.8.3

Used by

Popular packages that depend on yargs-parser.

Relationship graph

Dependencies (left) and dependents (right) of yargs-parser.

meowyargsyargs-parser
yargs-parser dependencies dependents

Frequently installed together

Release history

1 release in the last two years, typically about 13 days apart.

Recent versions of yargs-parser
VersionPublishedSizeLicense
22.0.0latest1 year ago84 KBISC
21.1.14 years ago125 KBISC
21.1.04 years ago131 KBISC
21.0.14 years ago123 KBISC
21.0.04 years ago123 KBISC
20.2.95 years ago122 KBISC
15.0.35 years ago61 KBISC
15.0.25 years ago61 KBISC
20.2.75 years ago119 KBISC
5.0.15 years ago38 KBISC
20.2.65 years ago118 KBISC
20.2.55 years ago118 KBISC
20.2.45 years ago117 KBISC
20.2.35 years ago117 KBISC
20.2.25 years ago116 KBISC

Overview

yargs-parser is an npm package that the mighty option parser used by yargs. It is extremely widely used, with about 178.8M downloads per week and 2 known dependents in the graph. The latest version is 22.0.0, released under the ISC license.

Who should use it

Teams working in the npm ecosystem who need the mighty option parser used by yargs and value a battle-tested, widely-adopted solution.

When not to use it

Consider an alternative if you need to minimize your dependency tree, have first-class TypeScript types out of the box, or if a more actively-maintained option better fits your npm stack.

Pros

  • Large, well-established user base (178.8M weekly downloads).
  • Clear open-source license (ISC).

Cons

  • Large dependency tree (18 direct dependencies) increases install size and audit surface.
  • No bundled TypeScript types (may require a separate @types package).

Auto-generated from collected registry metadata. No external claims are inferred.

Maintainers

Keywords

Frequently asked questions

Should I use yargs-parser?

yargs-parser is usable, with caveats. Last published 471 days ago.

How do I install yargs-parser?

Run `npm install yargs-parser` to add yargs-parser to your npm project.

What license is yargs-parser released under?

yargs-parser is distributed under the ISC license.

How popular is yargs-parser?

yargs-parser has approximately 178,824,999 downloads per week and 2 known dependent packages.

Is yargs-parser still maintained?

The most recent release of yargs-parser (v22.0.0) was published 1 year ago.

Does yargs-parser run install scripts?

No. yargs-parser does not define preinstall, install, or postinstall scripts, so installing it does not execute publisher-supplied code.