3 ms·
I am all for developer ergonomics, and I'm a fan of Ruby... but the problems this library would add to a codebase/project seem too big to be worth the benefits:
by TimTheTinker 6y ago
I am all for developer ergonomics, and I'm a fan of Ruby... but the problems this library would add to a codebase/project seem too big to be worth the benefits:
- non-standard syntax requiring its own documentation, which developers would have to consult separately (even if they already know regular expressions) to modify generated regular expressions
- removing the ability to test and validate regular expressions independently of the codebase (say, in the terminal, a small shell script, or using an online tool)
- a new rabbit hole to traverse when debugging a problem
- assuming the security risks associated with handing over regex-building to a library built by someone else (even more so if the regex is parsing private or protected data)
- adding a new dependency that may or may not be maintained in the future
For those who would want to use this library, I would suggest using a separate tool to build and/or understand regular expressions. Here's one example, and I'm sure there are others: https://regexr.com/ https://regexr.com/