-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.json
92 lines (92 loc) · 2.53 KB
/
.eslintrc.json
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
{
"settings": {
"react": {
"version": "detect"
},
"import/resolver": {
"node": {
"extensions": [".ts", ".tsx", ".d.ts"],
"moduleDirectory": [".", "node_modules"]
},
"alias": {
"map": [
["@/components", "./components"],
["@/app", "./app"],
["@/types", "./types"],
["@/assets", "./assets"],
["@/lib", "./lib"]
],
"extensions": [".ts", ".tsx", ".json", "css"]
},
"typescript": {
"alwaysTryTypes": true
}
}
},
"env": {
"browser": true,
"es2021": true,
"node": true
},
"extends": ["eslint:recommended", "plugin:react/recommended", "plugin:import/recommended", "plugin:jsx-a11y/recommended", "plugin:@typescript-eslint/recommended", "eslint-config-prettier", "plugin:prettier/recommended", "plugin:tailwindcss/recommended", "plugin:@next/next/recommended"],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 12,
"sourceType": "module"
},
"plugins": ["react", "@typescript-eslint", "react-hooks", "tailwindcss", "unused-imports"],
"rules": {
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": "off",
"unused-imports/no-unused-imports": "error",
"unused-imports/no-unused-vars": [
"warn",
{
"vars": "all",
"varsIgnorePattern": "^_",
"args": "after-used",
"argsIgnorePattern": "^_"
}
],
"prettier/prettier": ["error", {"endOfLine": "auto"}],
"jsx-a11y/role-supports-aria-props":[0],
"quotes": ["error", "double"],
"no-use-before-define": "off",
"@typescript-eslint/no-use-before-define": ["error"],
"react/function-component-definition": [
2,
{
"namedComponents": "arrow-function",
"unnamedComponents": "arrow-function"
}
],
"react/jsx-filename-extension": [
"warn",
{
"extensions": [".tsx"]
}
],
"no-shadow": "off",
"@typescript-eslint/no-shadow": ["error"],
"@typescript-eslint/explicit-function-return-type": [
"error",
{
"allowExpressions": true
}
],
"react-hooks/rules-of-hooks": "error",
"react-hooks/exhaustive-deps": "warn",
"import/prefer-default-export": "off",
"react/prop-types": "off",
"react/jsx-sort-props": [
2,
{
"callbacksLast": true,
"shorthandFirst": false,
"shorthandLast": true,
"ignoreCase": true,
"noSortAlphabetically": false
}
]
}
}