unjs
magic-regexp
TypeScript

A compiled-away, type-safe, readable RegExp alternative

Last updated Jul 6, 2026
4.3k
Stars
73
Forks
42
Issues
+1
Stars/day
Attention Score
90
Language breakdown
TypeScript 97.2%
JavaScript 2.8%
โ–ธ Files click to expand
README

๐Ÿฆ„ magic-regexp

[![npm version][npm-version-src]][npm-version-href] [![npm downloads][npm-downloads-src]][npm-downloads-href] [![Github Actions][github-actions-src]][github-actions-href] [![Codecov][codecov-src]][codecov-href] [![Bundlephobia][bundlephobia-src]][bundlephobia-href] nuxt.care health

A compiled-away, type-safe, readable RegExp alternative

Features

  • Runtime is zero-dependency and ultra-minimal
  • Ships with transform to compile to pure RegExp
  • Automatically typed capture groups
  • Natural language syntax
  • Generated RegExp displays on hover
๐Ÿ“–  Read more

๐Ÿ’ป Development

  • Clone this repository
  • Enable Corepack using corepack enable (use npm i -g corepack for Node.js < 16.10)
  • Install dependencies using pnpm install
  • Run interactive tests using pnpm dev

Similar packages

License

Made with โค๏ธ

Published under MIT License.

[npm-version-src]: https://npmx.dev/api/registry/badge/version/magic-regexp [npm-version-href]: https://npmx.dev/package/magic-regexp [npm-downloads-src]: https://npmx.dev/api/registry/badge/downloads/magic-regexp [npm-downloads-href]: https://npmx.dev/package/magic-regexp [github-actions-src]: https://img.shields.io/github/actions/workflow/status/danielroe/magic-regexp/ci.yml?branch=main&style=flat-square [github-actions-href]: https://github.com/danielroe/magic-regexp/actions?query=workflow%3Aci [codecov-src]: https://img.shields.io/codecov/c/gh/danielroe/magic-regexp/main?style=flat-square [codecov-href]: https://codecov.io/gh/danielroe/magic-regexp [bundlephobia-src]: https://img.shields.io/bundlephobia/minzip/magic-regexp?style=flat-square [bundlephobia-href]: https://bundlephobia.com/package/magic-regexp

ยฉ 2026 GitRepoTrend ยท unjs/magic-regexp ยท Updated daily from GitHub