Trial-and-error testing of regular expressions has always been a hassle for me – usually involving a decent amount of debugging, command-line testing and otherwise messing with code in a way that I ultimately have to revert before closing off.
Today while helping out a colleague, I was like “man, it would be cool if there was a regex fiddle”.
Turns out there are several, but the first real functional one I stumbled on – RegExr – seems pretty amazing.
You can check it out at http://regexr.com.
The “killer app” features that I personally like about RegExr in particular are the real-time expression compilation and match highlighting, and the highly informative tooltips – including listing backreference data when you mouse over matches. There is also a nicely set up left sidebar, with documentation, and links to community expressions (oh yeah, you can share the expressions you create with the world, of course).
The codebase is MIT Licensed as well, and be found on the GitHub repo.
This fine work seems to be the doing of one Edmontonian named Grant Skinner (http://gskinner.com) and his associates/employees. Thanks dude, if you’re ever in Vancouver I’ll buy you a beer. 🙂