fent/randexp.js
Create random strings that match a given regular expression. observed · 2026-08-28
Health v2 · maintenance only
47/100
- Activity 53
- Release rhythm 8
- Longevity 100
How is this computed?
round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10) — computed 2026-09-02. Adoption (stars, forks) is never an input.
- gap_med: n/a
- age_days: 5384
- days_rel: n/a
- days_push: 283
- n_releases_24m: 0
Adoption not part of the score
1867 stars · 94 forks observed · 2026-08-28
What it is AI-extracted, prompt v1, taxonomy v1, 2026-08-30, confidence not recorded
A JavaScript library that generates random strings matching a given regular expression. It supports grouping, ranges, references, custom character ranges, and pluggable PRNGs, working in Node.js and browsers.
Use cases
- generate random strings matching a regex
- create test data for form validation
- generate sample input for regex-based parsers
- seeded random string generation for reproducible tests
- generate mock usernames or identifiers from a pattern
When to choose
- you need test fixtures or mock data shaped by a regex pattern
- you want a small, dependency-free Node or browser library for random string generation
- you need custom character ranges or a seedable PRNG
When to avoid
- you need general-purpose fake data like names, addresses, or emails (use a faker library)
- your regexes use lookaheads or other constructs randexp cannot expand
- you need cryptographically secure output without supplying your own PRNG
Facets
library · maturity stable
data-generation testing parser developer-tools testing browser regex random-string-generation test-data mock-data automation nodejs javascript
2 sources
- readme: https://github.com/fent/randexp.js · fetched 2026-08-28 · 6e0ddd0ed829
- homepage: http://fent.github.io/randexp.js/ · fetched 2026-08-29 · 9b590ab435e5
Member repositories
| Repository | Role | Health v2 |
|---|---|---|
| fent/randexp.js | main | 47 |
For agents
Data as of 2026-08-30T08:39:29.467469+00:00 · Report a problem