This repository was archived by the owner on Dec 17, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 54
Expand file tree
/
Copy patheslint.config.js
More file actions
49 lines (48 loc) · 1.53 KB
/
eslint.config.js
File metadata and controls
49 lines (48 loc) · 1.53 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
// @ts-check
import storybook from "eslint-plugin-storybook";
import eslint from "@eslint/js";
import eslintReact from "@eslint-react/eslint-plugin";
import globals from "globals";
import reactHooks from "eslint-plugin-react-hooks";
import reactRefresh from "eslint-plugin-react-refresh";
import tseslint from "typescript-eslint";
import { globalIgnores } from "eslint/config";
import sonarJs from "eslint-plugin-sonarjs";
import prettier from "eslint-plugin-prettier/recommended";
export default tseslint.config(
[
globalIgnores(["dist", "storybook-static"]),
{
files: ["**/*.{ts,tsx}"],
extends: [
eslint.configs.recommended,
tseslint.configs.strictTypeChecked,
tseslint.configs.stylisticTypeChecked,
eslintReact.configs["recommended-type-checked"],
reactHooks.configs["recommended-latest"],
reactRefresh.configs.vite,
sonarJs.configs.recommended,
],
languageOptions: {
ecmaVersion: 2020,
globals: {
...globals.browser,
...globals.node,
},
parserOptions: {
parser: tseslint.parser,
tsconfigRootDir: import.meta.dirname,
project: ["./tsconfig.app.json"],
},
},
rules: {
"@typescript-eslint/no-unnecessary-type-parameters": "off",
"@eslint-react/no-use-context": "off",
"@eslint-react/no-context-provider": "off",
"react-refresh/only-export-components": "off",
},
},
],
storybook.configs["flat/recommended"],
prettier,
);