Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Numeric Range #74

Open
Lyiharilam opened this issue Jan 12, 2024 · 0 comments
Open

Numeric Range #74

Lyiharilam opened this issue Jan 12, 2024 · 0 comments

Comments

@Lyiharilam
Copy link

Hello, I was wondering if there is any capability to generate numeric ranges within your library. Specifically, if we consider a range with a start of 1 and an end of 17, the desired output would be something like ([1-9]|1[0-7]).

I'm curious if such functionality is already supported in your library, or if I might have overlooked it. I find everything about super-expressive to be great, and a feature like this would be incredibly useful.

If implementing numeric ranges proves to be challenging, could you consider adding the ability to use string subexpressions? This way, when using packages like to-regex-range for generating numeric ranges one could seamlessly insert their output just like in currently existing .subexpression but with string argument type instead of SuperExpressive instance.

For reference:
https://3widgets.com/
https://www.npmjs.com/package/to-regex-range

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant