Add and fix react hooks lint rules, single repertoire view
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import eslint from "@eslint/js";
|
||||
import tseslint from "typescript-eslint";
|
||||
import stylistic from "@stylistic/eslint-plugin";
|
||||
import reactHooks from "eslint-plugin-react-hooks";
|
||||
import tseslint from "typescript-eslint";
|
||||
|
||||
export default tseslint.config({
|
||||
extends: [
|
||||
@@ -10,6 +11,7 @@ export default tseslint.config({
|
||||
files: ["packages/*/src/**/*.{ts,tsx}"],
|
||||
plugins: {
|
||||
"@stylistic": stylistic,
|
||||
"react-hooks": reactHooks,
|
||||
},
|
||||
languageOptions: {
|
||||
parserOptions: {
|
||||
@@ -43,5 +45,7 @@ export default tseslint.config({
|
||||
"@typescript-eslint/no-explicit-any": "off",
|
||||
"@typescript-eslint/no-namespace": "off",
|
||||
"@typescript-eslint/no-misused-promises": ["error", { checksVoidReturn: false }],
|
||||
"react-hooks/exhaustive-deps": "error",
|
||||
"react-hooks/rules-of-hooks": "error",
|
||||
},
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user