News for hackers. Stuff that matters.
Re:ECMAScript regular expressions are getting better (2017) by arkh on Wednesday November 28, 2018 @09:16AM (#18551571)
Most regexp libraries let you use named groups and comments which let you write more maintainable expressions. The fact javascript does not may explain why so many people don't know how to use them.

https://www.regular-expressions.info/freespacing.html https://www.regular-expressions.info/named.html

Re:ECMAScript regular expressions are getting better (2017) by chrissam on Wednesday November 28, 2018 @10:44AM (#18552396)
ES2018 introduces named capture groups.

They're available today in Chrome, unsure about other browsers.

Re:ECMAScript regular expressions are getting better (2017) by gmac on Wednesday November 28, 2018 @09:30AM (#18551688)
You can have some of this in JS too by using libraries such as this one (which is mine): https://github.com/jawj/js-xre
Re:ECMAScript regular expressions are getting better (2017) by tlarkworthy on Wednesday November 28, 2018 @09:31AM (#18551700)
It does now! (named capture groups)