Named reference
captureAs`name``foo`.ref`name`
RegExp equivalent:
/(?<name>foo)\k<name>/
Number reference
capture`foo`.ref(1)
RegExp equivalent:
/(foo)\1/
Supply a number to reference the capture group with that index. Supply a string to reference a named capture group.
Rest
...args: unknown[]Named reference
captureAs`name``foo`.ref`name`
RegExp equivalent:
/(?<name>foo)\k<name>/
Number reference
capture`foo`.ref(1)
RegExp equivalent:
/(foo)\1/
Supply a number to reference the capture group with that index. Supply a string to reference a named capture group.
Named reference
captureAs`name``foo`.ref`name`
RegExp equivalent:
/(?<name>foo)\k<name>/
Number reference
capture`foo`.ref(1)
RegExp equivalent:
/(foo)\1/
Generated using TypeDoc
Supply a number to reference the capture group with that index. Supply a string to reference a named capture group.