WebUI: Enable @typescript-eslint/no-unused-vars check by default.
Note that even though the check is enabled in the default
src/.eslintrc.js config, it still only applies to folders that
call web_dev_style.presubmit_support.CheckStyle() in their
PRESUBMIT.py.
Bug: 1300123
Change-Id: Iaa2678073ac35ab4c9b40d1d4e83a05b3d565148
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3485119
Reviewed-by: John Lee <[email protected]>
Commit-Queue: Demetrios Papadopoulos <[email protected]>
Cr-Commit-Position: refs/heads/main@{#974553}
diff --git a/.eslintrc.js b/.eslintrc.js
index 7b88ee1..8cbbfd6 100644
--- a/.eslintrc.js
+++ b/.eslintrc.js
@@ -60,5 +60,17 @@
'overrides': [{
'files': ['**/*.ts'],
'parser': './third_party/node/node_modules/@typescript-eslint/parser',
+ 'plugins': [
+ '@typescript-eslint',
+ ],
+ 'rules': {
+ 'no-unused-vars': 'off',
+ '@typescript-eslint/no-unused-vars': [
+ 'error', {
+ argsIgnorePattern: '^_',
+ varsIgnorePattern: '^_',
+ }
+ ]
+ }
}]
};