camelcase rule should ignore global variables by default #11716
Labels
archived due to age
This issue has been archived; please open a new issue for any further discussion
auto closed
The bot closed this issue
enhancement
This change enhances an existing feature of ESLint
evaluating
The team will evaluate this issue to decide whether it meets the criteria for inclusion
rule
Relates to ESLint's core rules
What rule do you want to change?
camelcase
Does this change cause the rule to produce more or fewer warnings?
Change should produce fewer warnings
How will the change be implemented? (New option, new default behavior, etc.)?
Change should be implemented as a new default behavior.
Please provide some example code that this change will affect:
What does the rule currently do for this code?
Produces an error "Identifier 'g_form' is not in camel case." unless the variable is set as exception in camelcase rule allow property.
What will the rule do after it's changed?
In case the defined global variable is not present for the script, setting the variable as an exception in the camelcase rule would allow the developer to set said variable in the script and therefore avoid checks for camelcase. This is even more potentially harmful if you set up these variables as a regular expression.
Are you willing to submit a pull request to implement this change?
Not at the moment.
The text was updated successfully, but these errors were encountered: