Regular Expressions 101

Community Patterns

Community Library Entry

0

Regular Expression
ECMAScript (JavaScript)

/
(?<!\\)\((\?<(?<name>[\w][\w\d_]+)>|(?=[^\?]))
/
gm

Description

Find all capture groups in RegExp source. All forms of None-capture groups are ignored. name of named capture group will be captured by the name "name" which is group[2].

Submitted by anonymous - 5 years ago