-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc
112 lines (112 loc) · 3.27 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
107
108
109
110
111
112
{
"extends": ["plugin:import/errors", "plugin:import/warnings", "airbnb", "airbnb/hooks", "prettier", "plugin:prettier/recommended", "prettier/react", "plugin:react/recommended"],
"plugins": ["import", "react", "jsx-a11y", "react-hooks", "babel", "module-resolver"],
"root": true,
"rules": {
"react/jsx-filename-extension": [
2,
{
"extensions": [".js", ".jsx"]
}
],
"react/prop-types": 0,
"implicit-arrow-linebreak": 0,
"prefer-destructuring": 1,
"react/no-unused-state": 1,
"react/destructuring-assignment": 1,
"react/no-array-index-key": 1,
"react/jsx-key": [2],
"react-hooks/rules-of-hooks": "error",
"react-hooks/exhaustive-deps": "warn",
"react/jsx-no-duplicate-props": [2],
"react/jsx-uses-vars": [2],
"react/jsx-uses-react": [2],
"react/jsx-no-undef": ["error", { "allowGlobals": true}],
"react/no-direct-mutation-state": [2],
"react/require-optimization": [1],
"react/require-render-return": [2],
"jsx-a11y/img-has-alt": [0],
"jsx-a11y/img-redundant-alt": [2],
"no-nested-ternary": "off",
"no-plusplus": ["error", { "allowForLoopAfterthoughts": true }],
"no-underscore-dangle": ["error", { "allowAfterThis": true }],
"no-unused-expressions": ["error", {
"allowShortCircuit": true,
"allowTernary": true,
"allowTaggedTemplates": true
}],
"no-use-before-define": [
"error",
{ "functions": true, "classes": true, "variables": false }
],
"import/imports-first": ["error", "absolute-first"],
"import/no-unresolved": 0,
"import/newline-after-import": "error",
"import/prefer-default-export": 0,
"import/no-cycle": [2, { "maxDepth": 1, "ignoreExternal": true }],
"import/no-absolute-path": [2, { "esmodule": false, "commonjs": false, "amd": false }],
"prettier/prettier": ["error", {}, {
"usePrettierrc": true
}],
"quotes": [
"error",
"single",
{ "avoidEscape": true, "allowTemplateLiterals": false }
],
"max-len": ["error", {"code": 205, "ignoreUrls": true}],
"no-tabs": ["error", {"allowIndentationTabs": true}],
"babel/arrow-parens": [0, "as-needed"],
"babel/no-unused-expressions": 1,
"babel/valid-typeof": 1,
"module-resolver/use-alias": 2
},
"globals": {
"window": true,
"document": true,
"localStorage": true,
"FormData": true,
"FileReader": true,
"Blob": true,
"navigator": true
},
"env": {
"es2020": true,
"node": true,
"browser": true
},
"settings": {
"react": {
"version": "16.13.1"
},
"import/resolver": {
"babel-module": {
"root": ["./src"],
"alias": {
"@assets": "./src/assets",
"@config": "./src/config",
"@constants": "./src/constants",
"@hooks": "./src/hooks",
"@sharedComponents": "./src/sharedComponents",
"@commonActions": "./src/app/CommonActions",
"@pages":"./src/app/Pages",
"@utils": "./src/utils"
}
},
"node": {
"root": ["."],
"extensions": [
".js",
".jsx"
]
}
}
},
"parser": "babel-eslint",
"parserOptions": {
"sourceType": "module",
"ecmaFeatures": {
"jsx": true,
"modules": true
}
}
}