From 3dd1047b085fa7795f322c5829f39208465bff13 Mon Sep 17 00:00:00 2001 From: Sebastian Date: Tue, 29 Mar 2022 09:58:06 -0300 Subject: added react eslint and fix most of the warns --- .eslintrc.js | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to '.eslintrc.js') diff --git a/.eslintrc.js b/.eslintrc.js index 5d6ba1e72..01e64163d 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,12 +1,23 @@ module.exports = { root: true, parser: "@typescript-eslint/parser", - plugins: ["import","@typescript-eslint"], + plugins: ["import","@typescript-eslint", + "react", + "react-hooks", + ], extends: [ "eslint:recommended", "plugin:@typescript-eslint/eslint-recommended", "plugin:@typescript-eslint/recommended", + "plugin:react/recommended", + "plugin:react-hooks/recommended", ], + settings: { + react: { + pragma: 'h', + version: '16.0' + } + }, rules: { "no-constant-condition": ["error", { "checkLoops": false }], "prefer-const": ["warn", { destructuring: "all" }], @@ -25,5 +36,8 @@ module.exports = { { functions: false, classes: false }, ], "import/extensions": ["error", "ignorePackages"], + "react/no-unknown-property": 0, + "react/prop-types": 0, + }, }; -- cgit v1.2.3