-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.json
153 lines (153 loc) · 4.61 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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
{
"extends": [
"eslint:recommended",
"plugin:react/recommended",
"plugin:@typescript-eslint/recommended",
"plugin:prettier/recommended"
],
"plugins": [
"react",
"import-newlines",
"@typescript-eslint",
"prettier",
"simple-import-sort"
],
"rules": {
"simple-import-sort/imports": "error",
"simple-import-sort/exports": "error",
"react/no-unescaped-entities": "off",
"prettier/prettier": "off",
"react/jsx-uses-react": "off",
"react/react-in-jsx-scope": "off",
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": "warn",
"no-console": "warn",
"no-empty-pattern": "warn",
"no-extra-boolean-cast": "warn",
"no-constant-condition": "warn",
"no-invalid-this": "warn",
"quotes": ["warn", "double"],
"jsx-quotes": ["warn", "prefer-double"],
"semi": ["warn", "never"],
"indent": ["warn", 2, {
"SwitchCase": 1
}],
"max-len": ["warn", {
"code": 200,
"ignoreStrings": true
}],
"no-duplicate-imports": "off",
"no-trailing-spaces": "warn",
"no-multi-spaces": "warn",
"no-multiple-empty-lines": ["warn", {
"max": 1,
"maxEOF": 0
}],
"eqeqeq": ["warn", "always"],
"object-curly-spacing": ["warn", "always"],
"rest-spread-spacing": "warn",
"semi-spacing": "warn",
"semi-style": "warn",
"space-before-blocks": "warn",
"space-before-function-paren": ["warn", {
"anonymous": "never",
"named": "never",
"asyncArrow": "always"
}],
"space-in-parens": "warn",
"space-infix-ops": "warn",
"space-unary-ops": "warn",
"switch-colon-spacing": "warn",
"template-curly-spacing": "warn",
"wrap-regex": "warn",
"no-else-return": "warn",
"no-empty": "warn",
"no-undef-init": "warn",
"no-unneeded-ternary": "warn",
"no-useless-rename": "warn",
"no-useless-return": "warn",
"no-var": "error",
"prefer-const": "warn",
"one-var": ["error", "never"],
"arrow-spacing": "warn",
"block-spacing": "warn",
"yoda": "warn",
"brace-style": "warn",
"comma-spacing": "warn",
"comma-dangle": "off",
"computed-property-spacing": "warn",
"dot-location": ["warn", "property"],
"eol-last": "warn",
"func-call-spacing": "warn",
"function-paren-newline": "warn",
"implicit-arrow-linebreak": "warn",
"key-spacing": "warn",
"keyword-spacing": "warn",
"multiline-ternary": ["warn", "always-multiline"],
"linebreak-style": ["warn", "unix"],
"no-whitespace-before-property": "warn",
"nonblock-statement-body-position": "warn",
"object-curly-newline": "warn",
"max-statements-per-line": ["warn", {
"max": 1
}],
"newline-per-chained-call": ["warn", {
"ignoreChainWithDepth": 3
}],
"prefer-object-spread": "warn",
"no-restricted-imports": ["error", {
"patterns": ["@mui/*/*/*", "!@mui/material/test-utils/*"]
}],
"react/jsx-no-duplicate-props": "warn",
"react/jsx-no-leaked-render": "warn",
"react/jsx-no-script-url": "error",
"react/jsx-no-target-blank": "warn",
"react/jsx-no-useless-fragment": ["off"],
"react/jsx-one-expression-per-line": "warn",
"react/jsx-pascal-case": "warn",
"react/jsx-tag-spacing": "warn",
"react/jsx-wrap-multilines": "warn",
"func-style": ["warn", "expression", {
"allowArrowFunctions": true
}],
"import-newlines/enforce": ["warn", {
"items": 1,
"max-len": 100,
"semi": false
}],
"react/no-children-prop": "error",
"react/jsx-curly-brace-presence": "warn",
"react/jsx-curly-spacing": ["warn", {
"when": "never",
"children": true
}],
"react/jsx-equals-spacing": "warn",
"react/jsx-filename-extension": ["warn", {
"extensions": [".js", ".jsx", ".tsx"]
}],
"react/jsx-key": "warn",
"react/jsx-fragments": "warn",
"react/jsx-closing-bracket-location": ["warn", "tag-aligned"],
"react/jsx-max-props-per-line": ["warn", { "maximum": 1 }],
"react/jsx-first-prop-new-line": ["warn", "multiline-multiprop"],
"react/self-closing-comp": ["warn", {
"component": true,
"html": true
}],
"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/no-duplicate-imports": "warn",
"@typescript-eslint/no-shadow": "warn",
"@typescript-eslint/consistent-type-imports": "warn",
"@typescript-eslint/comma-dangle": "warn",
"@typescript-eslint/member-delimiter-style": ["warn", {
"multiline": {
"delimiter": "comma",
"requireLast": false
},
"singleline": {
"delimiter": "comma",
"requireLast": false
}
}]
}
}