Skip to content

Commit

Permalink
feat: tweaking our use of the no-use-before-define rule in TS (#338)
Browse files Browse the repository at this point in the history
  • Loading branch information
erunion authored Mar 10, 2022
1 parent 6e21c8a commit fc82044
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions typescript.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,10 @@ module.exports = {
// The stock `no-unused-vars` ESlint rule doesn't play with TS.
'no-unused-vars': 'off',
'@typescript-eslint/no-unused-vars': ['error'],

// The stock `no-use-before-define` ESLint rule throws errors when TS interfaces, types, and
// enums are used before they're defined -- eventhough in TS that's OK.
'no-use-before-define': 'off',
'@typescript-eslint/no-use-before-define': ['error'],
},
};

0 comments on commit fc82044

Please sign in to comment.