DEV Community

Discussion on: How do you feel about regex?

Collapse
 
syxaxis profile image
George Johnson

Very useful BUT it's almost an entire language in it's own right. I kind of respect that and just skirt around it. I use online regex builders when I need a regex for a filter style func call and that's me and regex done with until next time!

There was an 300 page O'Reilly book sold at one point just on Regex and nothing else! That's how deep the rabbit hole goes on regex. If you can avoid regex, then do so, if you can't then make the expression simple and watertight by testing the heck out it. Regex is greedy and if you don't test it properly you will regret it later.