Javascript regular expressions aren’t that daunting — here’s how to design your own