</>PackageGraphPackageGraph

anymatch

npmv3.1.3TypeScript

Matches strings against configurable strings, globs, regular expressions, and/or functions

Not recommended for new projects

No — anymatch should not be adopted for new projects. Last published 1388 days ago.

  • ?Adoption: grade ?, Not reported by this registry.

    No download data reported for this package yet.

  • FMaintenance: grade F, Failing.

    Last published 1388 days ago.

  • AWeight: grade A, Excellent.

    Pulls in 2 transitive packages, about 110 KB installed.

  • ASupply chain: grade A, Excellent.

    No install scripts, 5 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 anymatch to a project.

2
Direct dependencies

Runtime packages this one declares itself.

2
Total installed

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

110 KB
Install size

Unpacked size of this package plus its entire runtime tree.

1
Tree depth

Longest resolved dependency chain below this package.

Licenses in the dependency tree

MIT

Every license you inherit by installing anymatch, not just its own. Check this before a legal review, not after.

Compatibility

Node.js
node >= 8
Module format
CommonJS only
TypeScript
Types included
Install scripts
None

Quick start

A usage example from the anymatch README.

const anymatch = require('anymatch');

const matchers = [ 'path/to/file.js', 'path/anyjs/**/*.js', /foo.js$/, string => string.includes('bar') && string.length > 10 ] ;

anymatch(matchers, 'path/to/file.js'); // true
anymatch(matchers, 'path/anyjs/baz.js'); // true
anymatch(matchers, 'path/to/foo.js'); // true
anymatch(matchers, 'path/to/bar.js'); // true
anymatch(matchers, 'bar.js'); // false

// returnIndex = true
anymatch(matchers, 'foo.js', {returnIndex: true}); // 2
anymatch(matchers, 'path/anyjs/foo.js', {returnIndex: true}); // 1
Example truncated — see the full README.

anymatch vs the alternatives

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

PackageWeekly downloadsDependentsLicenseLast release
anymatchthis page01ISC3 years ago
is-glob137.4M3MIT1 day ago
is-extglob01MIT1 day ago
escape-string-regexp316.5M8MIT1 day ago
is-regex75.1M1MIT1 day ago
globule01MIT1 day ago

Dependencies

Declared by anymatch v3.1.3. Runtime dependencies are installed with the package; dev dependencies are not.

Dev (2)

mocha ^6.1.3nyc ^14.0.0

Used by

Popular packages that depend on anymatch.

Relationship graph

Dependencies (left) and dependents (right) of anymatch.

picomatchnormalize-pathjest-haste-mapanymatch
anymatch dependencies dependents

Frequently installed together

Release history

No releases in the last two years, typically about 59 days apart.

Recent versions of anymatch
VersionPublishedSizeLicense
3.1.3latest3 years ago9.4 KBISC
3.1.25 years ago9.3 KBISC
3.1.17 years ago9.2 KBISC
3.1.07 years ago9.2 KBISC
3.0.37 years ago8.8 KBISC
3.0.27 years ago8.7 KBISC
3.0.17 years ago8.6 KBISC
3.0.07 years ago8.6 KBISC
2.0.08 years agoISC
1.3.29 years agoISC
1.3.011 years agoISC
1.2.111 years agoISC
1.2.011 years agoISC
1.1.011 years agoISC
1.0.012 years agoISC

Overview

anymatch is an npm package that matches strings against configurable strings, globs, regular expressions, and/or functions. It has 1 known dependents in the graph. The latest version is 3.1.3, released under the ISC license.

Who should use it

Teams working in the npm ecosystem who need matches strings against configurable strings, globs, regular expressions, and/or functions and value a focused solution.

When not to use it

Consider an alternative if you need to or if a more actively-maintained option better fits your npm stack.

Pros

  • Ships TypeScript type definitions.
  • Clear open-source license (ISC).

Cons

  • No significant drawbacks detected from available metadata.

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

Maintainers

Keywords

Frequently asked questions

Should I use anymatch?

No — anymatch should not be adopted for new projects. Last published 1388 days ago.

How do I install anymatch?

Run `npm install anymatch` to add anymatch to your npm project.

How many dependencies does anymatch have?

anymatch declares 4 direct dependencies and pulls in 2 packages in total once its runtime tree is resolved totalling about 110 KB on disk.

What license is anymatch released under?

anymatch is distributed under the ISC license.

How popular is anymatch?

npm does not publish download counts. Within PackageGraph's crawl, 1 known packages depend on anymatch.

Is anymatch still maintained?

The most recent release of anymatch (v3.1.3) was published 3 years ago.

Does anymatch run install scripts?

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