.
\d
\w
\s
[abc]
[^abc]
*
+
?
{3}
{3,}
*?
^
$
\b
(…)
(?:…)
(?<name>…)
(?=…)
(?<=…)
|
const re = /(?<user>[\w.+-]+)@(?<domain>[\w-]+\.[\w.]+)/g for (const m of text.matchAll(re)) { console.log(m.index, m[0], m.groups) }