|
|
|
|
|
by darekkay
1677 days ago
|
|
> how is e.g. Intellij supposed to spot them reliably and help you It depends on the language. JavaScript has a dedicated RegExp object. If you use the literal notation or constructor, you will always get IntelliJ support (unless you decide to use the constructor and extract the regex string for whatever reason). I _think_ you could also mark a standalone string variable with JSDoc to get IDE support, too. |
|