2 ms·
> [edit] Also, the API makes less sense because JavaScript isn't statically typed so you can make up the result object on the fly. But now you need to parse th
by masklinn 11y ago
> [edit] Also, the API makes less sense because JavaScript isn't statically typed so you can make up the result object on the fly.
But now you need to parse the string and correctly extract named groups before flogging that to the regex engine, whereas the other way around you do some string concatenation then match back on the groups by index.