Should unnecessary_raw_strings be enforced in RegExps? #3385
Labels
P3
A lower priority bug or feature request
type-question
A question about expected behavior or functionality
Describe the issue
I typically am in the habit of using raw strings with
RegExp
s. IMO this is a good habit to have, even if using raw strings for a particular pattern isn't strictly necessary. Using a raw string allows me to not have to think. Should using raw strings unnecessarily when constructing aRegExp
really be discouraged?In the meantime, I'll probably just be disabling
unnecessary_raw_strings
entirely.To Reproduce
Expected behavior
Perhaps relax the
unnecessary_raw_strings
lint if the string is used for aRegExp
?Bonus points if it also could recognize and ignore cases like:
although I'm far less concerned about that case.
The text was updated successfully, but these errors were encountered: