-
Notifications
You must be signed in to change notification settings - Fork 0
/
eslintrc
79 lines (79 loc) · 2.38 KB
/
eslintrc
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
{
"plugins": ["react", "@typescript-eslint", "testing-library", "jest-dom"],
"extends": [
"eslint:recommended",
"plugin:react-hooks/recommended",
"plugin:@typescript-eslint/recommended",
"plugin:testing-library/react",
"plugin:jest-dom/recommended"
],
"settings": {
"react": {
"version": "18.2.0"
},
"import/ignore": ["node_modules"]
},
"env": {
"browser": true,
"es6": true
},
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 6,
"sourceType": "module",
"ecmaFeatures": {
"jsx": true
}
},
"ignorePatterns": ["node_modules/", "dist/"],
"rules": {
"no-console": "warn",
"semi": [
"error", "always"
],
"indent": ["error", 2],
"quotes": ["error", "single"],
"comma-dangle": ["error", "never"],
"eol-last": ["error", "always"],
"arrow-parens": ["error", "as-needed", { "requireForBlockBody": true }],
"object-curly-spacing": ["error", "always"],
"react/jsx-closing-bracket-location": [1, "after-props"],
"no-param-reassign": ["error", { "props": true, "ignorePropertyModificationsFor": ["state"] }],
"key-spacing": ["warn", {
"beforeColon": false
}],
"keyword-spacing": ["warn", {
"before": true,
"after": true
}],
"react/function-component-definition": ["error", {
"namedComponents": "arrow-function",
"unnamedComponents": "arrow-function"
}],
"padding-line-between-statements": ["error", {
"blankLine": "always",
"prev": ["const", "let", "var"],
"next": "*"
}, {
"blankLine": "any",
"prev": ["const", "let", "var"],
"next": ["const", "let", "var"]
}],
"@typescript-eslint/array-type": "error",
"@typescript-eslint/explicit-function-return-type": "warn",
"@typescript-eslint/no-empty-function": "error",
"@typescript-eslint/type-annotation-spacing": ["error", {
"before": true, "after": true, "overrides": {
"colon": { "before": false, "after": true }}
}],
"@typescript-eslint/consistent-type-definitions": ["error", "interface"],
"@typescript-eslint/member-delimiter-style": "error",
"@typescript-eslint/no-unused-vars": "error",
"@typescript-eslint/typedef": ["error", {
"arrowParameter": false,
"memberVariableDeclaration": true,
"parameter": true,
"propertyDeclaration": true
}]
}
}