|
@mathias | |||||
|
🔥 JavaScript regular expressions are getting more powerful!
RegExp match objects now have an `indices` array that contains the start and end positions for each capturing group.
@MayaLekova explains: v8.dev/features/regex… pic.twitter.com/1923QdMchv
|
||||||
|
||||||
|
Tomas Grubliauskas
@agileSaturday
|
18. pro |
|
Noticed that when inspecting exec result at runtime. Was very useful for one of my side projects where I built a better in-page text search as Chrome extension
|
||
|
|
||
|
Mathias Bynens
@mathias
|
18. pro |
|
Where did you see this? It hasn't shipped yet!
|
||
|
|
||
|
Daniel Rodriguez del Villar 🇻🇪
@danielrvt
|
17. pro |
|
But still no named capturing groups 😪
|
||
|
|
||
|
Mathias Bynens
@mathias
|
17. pro |
|
Did you read the article? There’s an example that uses named capture groups!
Also see mathiasbynens.be/notes/es-regex…
|
||
|
|
||
|
Darien MV
@bhathos
|
17. pro |
|
thrilled with this! RegExp keeps getting more and more friendly to lexing
|
||
|
|
||
|
Thomas
@tfolbrecht
|
18. pro |
|
|
||
|
Didier FRANC
@DidierFranc
|
17. pro |
|
|
||
|
faelcavalcanti
@faelcavalcanti
|
17. pro |
|
where is the variable start and end? ... i’ll still read your article ... great work!
|
||
|
|
||
|
digital
@dev01ution
|
17. pro |
|
I needed this, in node
|
||
|
|
||
|
Mobile First 😎🔥
@MobileFirstLLC
|
18. pro |
|
What's a good emoji for the face I make every time I hear "powerful regex"... hmm... 🤔 Probably this sequence:
😱😖😭
|
||
|
|
||