From 3575af6cbf4b700fae28f10a61ce6f0cb6d3c9bb Mon Sep 17 00:00:00 2001 From: AndrewLeedham Date: Mon, 17 Jan 2022 12:02:00 +0000 Subject: [PATCH] Add ESLint TS checking rules + style enforcement --- packages/xerox-eslint-config/typescript.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/xerox-eslint-config/typescript.js b/packages/xerox-eslint-config/typescript.js index f4247667..76581b98 100644 --- a/packages/xerox-eslint-config/typescript.js +++ b/packages/xerox-eslint-config/typescript.js @@ -2,6 +2,7 @@ module.exports = { plugins: ['@typescript-eslint', 'jsdoc'], extends: [ 'plugin:@typescript-eslint/recommended', + 'plugin:@typescript-eslint/recommended-requiring-type-checking', 'plugin:import/typescript', ], parser: '@typescript-eslint/parser', @@ -38,6 +39,9 @@ module.exports = { ignoreRestSiblings: true, }, ], + '@typescript-eslint/array-type': 'error', + '@typescript-eslint/consistent-type-assertions': 'error', + '@typescript-eslint/no-unnecessary-condition': 'warn', 'jsdoc/check-examples': 'off', 'jsdoc/check-param-names': 'error', 'jsdoc/check-tag-names': [