-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
135 lines (133 loc) · 3.25 KB
/
.eslintrc.js
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
module.exports = {
"env": {
"es2021": true,
"node": true,
"jest": true,
"browser": true,
},
"extends": [
"eslint:recommended",
"airbnb-base",
"plugin:import/typescript",
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 12,
"ecmaFeatures": {
"jsx": true
},
"sourceType": "module",
"project": "tsconfig.json"
},
"plugins": [
"@typescript-eslint",
"@typescript-eslint/eslint-plugin",
"unused-imports",
"import-newlines",
"import",
"react",
"react-hooks"
],
"settings": {
"import/resolver": {
"typescript": {}
}
},
"ignorePatterns": "**/*.d.ts",
"rules": {
"no-console": ["error", { "allow": [ "warn", "error" ] }],
"no-continue": "off",
"no-restricted-syntax": "off",
"padded-blocks": ["error", { "classes": "always" }],
"max-classes-per-file": "off",
"class-methods-use-this": "off",
"indent": "off",
"@typescript-eslint/indent": ["error", 2],
"eqeqeq": "error",
"linebreak-style": ["error", "unix"],
"quotes": ["error", "double"],
"semi": ["error", "always"],
"no-shadow": "off",
"@typescript-eslint/no-shadow": "warn",
"import/prefer-default-export": ["off"],
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": [
"error",
{
"ignoreRestSiblings": true,
"argsIgnorePattern": "^_"
}
],
"camelcase": "off",
"@typescript-eslint/no-empty-function": "warn",
"unused-imports/no-unused-imports": "error",
"unused-imports/no-unused-vars": "off",
"object-curly-spacing": [2, "always"],
"object-curly-newline": [
"error",
{
"ObjectExpression": {
"multiline": true,
"minProperties": 2
},
"ObjectPattern": {
"multiline": true,
"minProperties": 3
},
"ExportDeclaration": "always"
}
],
"import-newlines/enforce": [
"error",
{
"items": 3,
"max-len": 80,
"semi": true
}
],
"array-bracket-spacing": ["error", "always"],
"@typescript-eslint/ban-ts-comment": "off",
"no-empty-pattern": "off",
"import/order": [
"warn",
{
"newlines-between": "always",
"groups": [
"builtin",
"external",
"internal",
"parent",
"sibling",
"index"
]
}
],
"import/extensions": [
"error",
"ignorePackages",
{
"js": "never",
"jsx": "never",
"ts": "never",
"tsx": "never"
}
],
"import/no-cycle": "off",
"import/no-dynamic-require": "off",
"import/no-extraneous-dependencies": "off",
"max-len": "off",
"no-useless-constructor": "off",
"no-empty-function": "off",
"no-unresolved": "off",
"global-require": "off",
"@typescript-eslint/no-floating-promises": "error",
"no-void": "off",
"no-use-before-define": "off",
"@typescript-eslint/no-use-before-define": ["off"],
"curly": "off",
"no-redeclare": "off",
"no-inner-declarations": "off",
"react-hooks/rules-of-hooks": "off", // Checks rules of Hooks
"react-hooks/exhaustive-deps": "off" // Checks effect dependencies
}
};