-
Notifications
You must be signed in to change notification settings - Fork 6
/
.eslintrc.json
56 lines (56 loc) · 2.24 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
{
"root": true,
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 6,
"sourceType": "module",
"ecmaFeatures": {
"modules": true
}
},
"plugins": ["@typescript-eslint", "react-hooks", "prettier"],
"extends": [
"eslint:recommended",
"prettier/@typescript-eslint",
// "plugin:prettier/recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
// "plugin:@typescript-eslint/recommended-requiring-type-checking"
// "standard"
],
"rules": {
"react-hooks/rules-of-hooks": "error",
"react-hooks/exhaustive-deps": "warn",
"prettier/prettier": ["error",{
"endOfLine": "auto"}
],
"camelcase": ["error"],
"eqeqeq": ["error"],
"dot-notation": ["off"], // replaced by "@typescript-eslint/dot-notation"
"lines-between-class-members": ["off"], // replaced by "@typescript-eslint/lines-between-class-members"
"no-async-promise-executor": ["warn"],
"no-case-declarations": ["warn"],
"no-constant-condition": ["warn"],
"no-extra-boolean-cast": ["warn"],
"no-irregular-whitespace": ["warn"],
"no-self-assign": ["warn"],
"no-unexpected-multiline": ["warn"],
"no-undef": ["off"],
"no-unneeded-ternary": ["warn"],
"no-unused-vars": ["off"], // replaced by "@typescript-eslint/no-unused-vars"
"no-use-before-define": ["off"], // replaced by "@typescript-eslint/no-use-before-define"
"no-var": ["error"],
"prefer-const": ["error"],
"use-isnan": ["error"],
// typescript-eslint rules
"@typescript-eslint/ban-types": ["off"],
"@typescript-eslint/explicit-module-boundary-types": ["off"],
"@typescript-eslint/dot-notation": ["off"],
"@typescript-eslint/lines-between-class-members": ["warn"],
"@typescript-eslint/no-explicit-any": ["off"],
"@typescript-eslint/no-inferrable-types": ["error"],
"@typescript-eslint/no-non-null-assertion": ["off"],
"@typescript-eslint/no-unused-vars": ["warn"],
"@typescript-eslint/no-use-before-define": ["error"]
}
}