Extract @Mentions

Extract all @mentions from a text string.

Code

General
text.match(/@\w+/g) || [];

Parameters

Text containing @mentions

Browser·fetch() may be limited by CORS

More JavaScript Snippets