brace-expansion
npmv5.0.9TypeScriptBrace expansion as known from sh/bash
Safe to adopt
Yes — brace-expansion scores well across adoption, maintenance, weight, supply chain, and licensing. 612.2M downloads per week and 1 known dependents. Last published 41 days ago. 29 releases in the last 2 years.
- AAdoption: grade A, Excellent.
612.2M downloads per week and 1 known dependents.
- AMaintenance: grade A, Excellent.
Last published 41 days ago. 29 releases in the last 2 years.
- AWeight: grade A, Excellent.
Pulls in 1 transitive package, about 86 KB installed.
- ASupply chain: grade A, Excellent.
No install scripts, 2 maintainers, and a contained dependency surface.
- ALicense: grade A, Excellent.
MIT — 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 brace-expansion to a project.
Runtime packages this one declares itself.
Distinct packages in the full runtime tree, deduplicated the way a package manager would.
Unpacked size of this package plus its entire runtime tree.
Longest resolved dependency chain below this package.
Licenses in the dependency tree
Every license you inherit by installing brace-expansion, not just its own. Check this before a legal review, not after.
Compatibility
- Node.js
- node 20 || >=22
- Module format
- ESM + CommonJS
- TypeScript
- Types included
- Install scripts
- None
Quick start
A usage example from the brace-expansion README.
import { expand } from 'brace-expansion'
expand('file-{a,b,c}.jpg')
// => ['file-a.jpg', 'file-b.jpg', 'file-c.jpg']
expand('-v{,,}')
// => ['-v', '-v', '-v']
expand('file{0..2}.jpg')
// => ['file0.jpg', 'file1.jpg', 'file2.jpg']
expand('file-{a..c}.jpg')
// => ['file-a.jpg', 'file-b.jpg', 'file-c.jpg']
Dependencies
Declared by brace-expansion v5.0.9. Runtime dependencies are installed with the package; dev dependencies are not.
Runtime (1)
Dev (7)
Used by
Popular packages that depend on brace-expansion.
Relationship graph
Dependencies (left) and dependents (right) of brace-expansion.
Frequently installed together
Release history
29 releases in the last two years, typically about 1 day apart.
| Version | Published | Size | License |
|---|---|---|---|
| 1.1.18 | 1 month ago | 18 KB | MIT |
| 2.1.4 | 1 month ago | 16 KB | MIT |
| 3.0.6 | 1 month ago | 18 KB | MIT |
| 5.0.9latest | 1 month ago | 69 KB | MIT |
| 1.1.17 | 1 month ago | 17 KB | MIT |
| 3.0.5 | 1 month ago | 17 KB | MIT |
| 2.1.3 | 1 month ago | 16 KB | MIT |
| 3.0.4 | 1 month ago | 17 KB | MIT |
| 3.0.3 | 1 month ago | 36 MB | MIT |
| 5.0.8 | 1 month ago | 63 KB | MIT |
| 2.1.2 | 2 months ago | 143 KB | MIT |
| 1.1.16 | 2 months ago | 143 KB | MIT |
| 5.0.7 | 2 months ago | 50 KB | MIT |
| 1.1.15 | 3 months ago | 11 KB | MIT |
| 2.1.1 | 3 months ago | 11 KB | MIT |
Overview
brace-expansion is an npm package that brace expansion as known from sh/bash. It is extremely widely used, with about 612.2M downloads per week and 1 known dependents in the graph. The latest version is 5.0.9, released under the MIT license.
Who should use it
Teams working in the npm ecosystem who need brace expansion as known from sh/bash and value a battle-tested, widely-adopted 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
- Large, well-established user base (612.2M weekly downloads).
- Ships TypeScript type definitions.
- Clear open-source license (MIT).
Cons
- No significant drawbacks detected from available metadata.
Auto-generated from collected registry metadata. No external claims are inferred.
Maintainers
Frequently asked questions
Should I use brace-expansion?
Yes — brace-expansion scores well across adoption, maintenance, weight, supply chain, and licensing. 612.2M downloads per week and 1 known dependents. Last published 41 days ago. 29 releases in the last 2 years.
How do I install brace-expansion?
Run `npm install brace-expansion` to add brace-expansion to your npm project.
How many dependencies does brace-expansion have?
brace-expansion declares 8 direct dependencies and pulls in 1 packages in total once its runtime tree is resolved totalling about 86 KB on disk.
What license is brace-expansion released under?
brace-expansion is distributed under the MIT license.
How popular is brace-expansion?
brace-expansion has approximately 612,242,916 downloads per week and 1 known dependent packages.
Is brace-expansion still maintained?
The most recent release of brace-expansion (v5.0.9) was published 1 month ago.
Does brace-expansion run install scripts?
No. brace-expansion does not define preinstall, install, or postinstall scripts, so installing it does not execute publisher-supplied code.