Closed
Description
Repro
{
"rules": {
"@typescript-eslint/naming-convention": [
"error",
{
"selector": "default",
"format": ["strictCamelCase"]
}
]
}
}
onComplete: (_id, name, responseJson) => {
// Using name and responseJson, but not id.
}
Expected Result
No error on _id
.
Actual Result
Error on _id
.
Additional Info
As mentioned here with Brad's response here.
When using the noUnusedParameters
compiler option, you have to use an underscore to suppress TypeScript's error. However, this shouldn't be done unless the parameter is actually unused.
Versions
package | version |
---|---|
@typescript-eslint/eslint-plugin |
2.16.0 |
@typescript-eslint/parser |
2.16.0 |
TypeScript |
3.7.5 |
ESLint |
6.8.0 |
node |
12.14.1 |
npm |
6.13.4 |