We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
for
I would like to set a different for naming-convention rules for control variables defined in for loop.
For instance:
function fooBar() { for (let i = 0, j = 10; i < 10; i++, j--) { let _local = 2; console.log (`${i} ${_local*i} => ${j} ${_local*j); } }
With the below tslint.json setting, tslint warns variable name must have leading underscore (naming-convention) for loop control variables i & j
tslint.json
tslint
variable name must have leading underscore (naming-convention)
i
j
"naming-convention": [ true, { "type": "variable", "modifiers": "local", "leadingUnderscore": "require" } ]
I would like to add a new convention rule for overriding control variables defines in for loop.
The text was updated successfully, but these errors were encountered:
I would advise to add a new type loopControlVariable
loopControlVariable
Sorry, something went wrong.
No branches or pull requests
I would like to set a different for naming-convention rules for control variables defined in
for
loop.For instance:
With the below
tslint.json
setting,tslint
warnsvariable name must have leading underscore (naming-convention)
for loop control variablesi
&j
I would like to add a new convention rule for overriding control variables defines in
for
loop.The text was updated successfully, but these errors were encountered: