forked from saeloun/miru-web
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc
106 lines (106 loc) · 3.17 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
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
{
"root": true,
"parser": "@typescript-eslint/parser",
"parserOptions": {
"project": "./tsconfig.json",
"sourceType": "module"
},
"env": {
"es6": true,
"node": true,
"jest": true
},
"extends": [
"eslint:recommended",
"plugin:react/recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
],
"settings": {
"import/extensions": [
".js",
".jsx",
".ts",
".tsx"
],
"import/parsers": {
"@typescript-eslint/parser": [
".ts",
".tsx"
]
},
"import/resolver": {
"node": {
"extensions": [
".js",
".jsx",
".ts",
".tsx"
]
}
},
"react": {
"pragma": "React",
"fragment": "Fragment",
"version": "detect"
}
},
"plugins": [
"react",
"import",
"@typescript-eslint"
],
"globals": {
"fetch": false,
"document": false,
"Promise": true,
"log": true,
"sessionStorage": true,
"localStorage": true,
"FileReader": true,
"window": true
},
"rules": {
"@typescript-eslint/no-explicit-any": "off",
"object-curly-newline": "off",
"no-console": ["error", { "allow": ["warn", "error"] }],
"comma-dangle": ["error", "never"],
"indent": ["warn", 2, { "SwitchCase": 1 }],
"@typescript-eslint/no-unused-vars": ["error"],
"key-spacing": 1,
"keyword-spacing": 2,
"object-curly-spacing": [1, "always"],
"semi": 2,
"array-bracket-spacing": [2, "never"],
"arrow-body-style": ["error", "as-needed"],
"func-style": ["error", "expression"],
"space-before-function-paren": 2,
"no-multiple-empty-lines": ["warn", { "max": 1, "maxEOF": 1 }],
"quotes": ["warn", "double"],
"prefer-const": ["warn", { "destructuring": "any", "ignoreReadBeforeAssign": false }],
"no-var": 1,
"no-extra-boolean-cast": 1,
"no-unneeded-ternary": 1,
"react/no-unescaped-entities": 0,
"react/prop-types": 0,
"react/jsx-key": 0,
"import/order": ["error", {
"newlines-between": "always",
"alphabetize": { "order": "asc", "caseInsensitive": true },
"warnOnUnassignedImports": true,
"groups": ["builtin", "external", "internal", "sibling", "parent", "index", "object", "type"],
"pathGroups": [
{ "pattern": "react", "group": "builtin", "position": "before" },
{ "pattern": "common/**", "group": "internal" },
{ "pattern": "context/**", "group": "internal" },
{ "pattern": "components/**", "group": "internal" },
{ "pattern": "assets/**", "group": "internal" },
{ "pattern": "apis/**", "group": "internal" },
{ "pattern": "constants/**", "group": "internal", "position": "after" },
{ "pattern": "utils/**", "group": "internal" },
{ "pattern": "helpers/**", "group": "internal" }
],
"pathGroupsExcludedImportTypes": ["builtin"]
}]
}
}