Skip to content

Commit

Permalink
fix(unused-imports): unused imports will now be highlighted as errors
Browse files Browse the repository at this point in the history
  • Loading branch information
BLuEScioN committed Jan 23, 2023
1 parent 8168e06 commit 448ed09
Show file tree
Hide file tree
Showing 3 changed files with 303 additions and 336 deletions.
3 changes: 2 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module.exports = {
'prettier',
],
parser: '@typescript-eslint/parser',
plugins: ['import', '@typescript-eslint', 'prettier'],
plugins: ['import', '@typescript-eslint', 'prettier', 'unused-imports'],
settings: {
'import/parsers': {
'@typescript-eslint/parser': ['.ts', '.tsx'],
Expand Down Expand Up @@ -80,5 +80,6 @@ module.exports = {

// TODO: enable this when reasonable
'@typescript-eslint/promise-function-async': 'off',
'unused-imports/no-unused-imports': 'error',
},
};
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@
"eslint-config-prettier": "^8.3.0",
"eslint-import-resolver-typescript": "2.5.0",
"eslint-plugin-import": "2.25.3",
"eslint-plugin-prettier": "4.0.0"
"eslint-plugin-prettier": "4.0.0",
"eslint-plugin-unused-imports": "^2.0.0"
},
"devDependencies": {
"typescript": "4.5.2"
Expand Down
Loading

0 comments on commit 448ed09

Please sign in to comment.