mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-06-10 06:39:01 +02:00
Modify no-unused-vars behaviour
using @typescript-eslint/no-unused-vars reduces the number of false positives in TS code. The changes: 1. Allow the arguments to a function to be checked (reporting only after the last used variable) 2. Allow rest siblings to be checked 3. Allow these rules to be skipped with an _ prefix to a variable GitOrigin-RevId: 1f6eac4109859415218248d5b2068a22b34cfd7e
This commit is contained in:
@@ -383,6 +383,18 @@ module.exports = {
|
||||
'Modify location via customLocalStorage instead of calling window.localStorage methods directly',
|
||||
},
|
||||
],
|
||||
'no-unused-vars': 'off',
|
||||
'@typescript-eslint/no-unused-vars': [
|
||||
'error',
|
||||
{
|
||||
args: 'after-used',
|
||||
argsIgnorePattern: '^_',
|
||||
ignoreRestSiblings: false,
|
||||
caughtErrors: 'none',
|
||||
vars: 'all',
|
||||
varsIgnorePattern: '^_',
|
||||
},
|
||||
],
|
||||
},
|
||||
},
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user