New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
no-invalid-regexp: Make allowConstructorFlags option case sensitive #16574
Comments
I'm not sure why this option was made to be case-insensitive. There's no mention of this in #5352 or #5249. By looking at the changes from #5352, it seems intentional as the regex that processes the option has the I agree that this option should be case-sensitive, so that Since this was apparently intentional, I'd like more input from the team on whether we should make this change (any ideas why this option is case-insensitive?) and whether we can treat it as a semver-minor bug fix. |
Oops! It looks like we lost track of this issue. What do we want to do here? This issue will auto-close in 7 days without an update. |
I'm 👍🏻 on this proposal as I also feel it should be case-sensitive. This would be a breaking change definitely so it should fall under the next major release. |
Oops! It looks like we lost track of this issue. What do we want to do here? This issue will auto-close in 7 days without an update. |
Marking this as accepted and adding it to the v9 board for tracking. |
Edit: please disregard, I updated wrong issue. |
#17533 is ready for review. Marked as draft for now as it's a breaking change. |
Hi,
The
allowConstructorFlags
option of theno-invalid-regexp
rule is case insensitive.I believe that the option should be treated as case sensitive (because regexp flags are case sensitive).
What rule do you want to change?
no-invalid-regexp
What change to do you want to make?
Generate more warnings
How do you think the change should be implemented?
A new default behavior
Example code
What does the rule currently do for this code?
The rule treats the option as case insensitive, and reports no issues.
What will the rule do after it's changed?
The rule should IMO report invalid flag.
Participation
Additional comments
No response
The text was updated successfully, but these errors were encountered: