From b29bb6e38fffd48664ebae14cb3b529547d1e613 Mon Sep 17 00:00:00 2001 From: Jon Ursenbach Date: Wed, 9 Mar 2022 16:16:21 -0800 Subject: [PATCH] feat: tweaking our use of the `no-use-before-define` rule in TS --- typescript.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/typescript.js b/typescript.js index 9fcbe506..885f92a8 100644 --- a/typescript.js +++ b/typescript.js @@ -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'], }, };