Should we allow for passing compiled regex strings? #14
Closed
mdjastrzebski
started this conversation in
Ideas
Replies: 3 comments 2 replies
-
I also lean into "beginner-friendly" approach. Maybe we can add |
Beta Was this translation helpful? Give feedback.
2 replies
-
Yeah, I'll write it down in some project assumptions doc, somewhere... |
Beta Was this translation helpful? Give feedback.
0 replies
-
Example from Swift RegexBuilder shows that they're escaping "." that user passed when trying to validate regex, so it confirms our approach with "beginner-friendly". |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
How should we handle cases when string value passed by the user to the builder contains special Regex meaning, e.g.,
We have to options here:
We should establish Swift RB behavior in this regard, as that would be important factor.
Personally I would lean toward "beginner-friendly" as we strive to make Regex easy to use, and allowing for regex special chars, could result in hard to diagnose errors, that would be surprise for users new to regex.
@okwasniewski, @jaworek wdyt?
Beta Was this translation helpful? Give feedback.
All reactions