-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.json
87 lines (87 loc) · 2.39 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
{
"root": true,
"parser": "@typescript-eslint/parser",
"settings": {
"import/resolver": {
"alias": {
"map": [["~", "./"]],
"extensions": [".ts", ".js", ".tsx"]
},
"typescript": {
"project": "./tsconfig.json"
}
}
},
"plugins": ["react-hooks", "@typescript-eslint", "import", "simple-import-sort", "unused-imports", "prettier"],
"extends": [
"next/core-web-vitals",
"plugin:react/recommended",
"plugin:react-hooks/recommended",
"plugin:@typescript-eslint/recommended",
"plugin:prettier/recommended"
],
"rules": {
"require-jsdoc": "off",
"semi": "off",
"comma-dangle": [
"warn",
{
"arrays": "always-multiline",
"objects": "always-multiline",
"imports": "always-multiline",
"exports": "always-multiline",
"functions": "always-multiline"
}
],
"no-underscore-dangle": 0,
"@typescript-eslint/semi": ["warn", "never"],
"@typescript-eslint/consistent-type-imports": "error",
"@typescript-eslint/explicit-module-boundary-types": "off",
"@typescript-eslint/no-use-before-define": "off",
"@typescript-eslint/no-explicit-any": "error",
"react/prop-types": "off",
"no-console": ["error", { "allow": ["warn", "error"] }],
"@typescript-eslint/no-unused-vars": [
"error",
{
"varsIgnorePattern": "^_",
"argsIgnorePattern": "^_"
}
],
"no-use-before-define": "off",
"import/prefer-default-export": "off",
"unused-imports/no-unused-imports-ts": 2,
"import/no-cycle": 1,
"import/extensions": 0,
"sort-imports": "off",
"import/first": "error",
"import/newline-after-import": "error",
"import/no-duplicates": "error",
"react/jsx-uses-react": "off",
"react/react-in-jsx-scope": "off",
"simple-import-sort/exports": "error",
"simple-import-sort/imports": [
"error",
{
"groups": [
["^react$", "^react", "^@react"],
["^@?\\w"],
["~/."],
["^\\.\\.(?!/?$)", "^\\.\\./?$"],
["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"]
]
}
],
"prettier/prettier": ["error", { "bracketSpacing": "1" }]
},
"overrides": [
{
"files": ["*.ts", "*.tsx"],
"rules": {
"@typescript-eslint/no-shadow": ["error"],
"no-shadow": "off",
"no-undef": "off"
}
}
]
}