| 1 | import tsPlugin from "@typescript-eslint/eslint-plugin"; |
| 2 | import tsParser from "@typescript-eslint/parser"; |
| 3 | import reactHooks from "eslint-plugin-react-hooks"; |
| 4 | import reactRefresh from "eslint-plugin-react-refresh"; |
| 5 | |
| 6 | export default [ |
| 7 | { |
| 8 | ignores: ["dist/**", "node_modules/**"], |
| 9 | }, |
| 10 | { |
| 11 | files: ["**/*.{ts,tsx}"], |
| 12 | languageOptions: { |
| 13 | parser: tsParser, |
| 14 | ecmaVersion: 2022, |
| 15 | sourceType: "module", |
| 16 | }, |
| 17 | plugins: { |
| 18 | "@typescript-eslint": tsPlugin, |
| 19 | "react-hooks": reactHooks, |
| 20 | "react-refresh": reactRefresh, |
| 21 | }, |
| 22 | rules: { |
| 23 | ...tsPlugin.configs.recommended.rules, |
| 24 | ...reactHooks.configs.recommended.rules, |
| 25 | "@typescript-eslint/no-explicit-any": "off", |
| 26 | "react-hooks/purity": "off", |
| 27 | "react-hooks/set-state-in-effect": "off", |
| 28 | "react-hooks/static-components": "off", |
| 29 | "react-refresh/only-export-components": "off", |
| 30 | }, |
| 31 | }, |
| 32 | ]; |