-
Notifications
You must be signed in to change notification settings - Fork 17
/
.eslintrc.json
executable file
·95 lines (95 loc) · 2.8 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
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
{
"root": true,
// "parser": "babel-eslint",
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaFeatures": {
"jsx": true
},
"ecmaVersion": 2018,
"sourceType": "module",
"project": ["./frontend/tsconfig.json", "./api/tsconfig.json"],
"tsconfigRootDir": "src"
},
"env": {
"browser": true,
"es6": true,
"node": true,
"jest": true
},
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
//"plugin:@typescript-eslint/recommended-requiring-type-checking"
"standard",
"plugin:react/recommended",
"plugin:jsx-a11y/recommended",
"prettier/@typescript-eslint", // Uses eslint-config-prettier to disable ESLint rules from @typescript-eslint/eslint-plugin that would conflict with prettier
"plugin:prettier/recommended",
"plugin:import/errors",
"plugin:import/warnings",
"plugin:import/typescript",
"plugin:security/recommended"
],
"settings": {
"react": {
"version": "latest"
},
"import/extensions": [".js", ".jsx", ".ts", ".tsx"],
"import/parsers": {
"@typescript-eslint/parser": [".ts", ".tsx"]
}
},
"plugins": ["@typescript-eslint/eslint-plugin", "import", "prettier", "standard", "react", "jsx-a11y", "security"],
"rules": {
//"no-unused-variable": "warn",
"import/no-unresolved": "error",
"import/named": "error",
"import/namespace": "error",
"import/default": "error",
"import/export": "error",
"import/no-absolute-path": "error",
"import/no-self-import": "error",
"import/no-cycle": "error",
"import/no-named-as-default": "error",
"import/no-named-as-default-member": "error",
"import/no-mutable-exports": "error",
"import/no-unused-modules": "warn",
"import/first": "error",
"import/exports-last": "error",
"import/no-duplicates": "error",
"import/order": "error",
"import/newline-after-import": "error",
"import/no-named-default": "error",
"import/no-default-export": "error",
"import/no-anonymous-default-export": "error",
"@typescript-eslint/promise-function-async": "error",
"@typescript-eslint/no-misused-promises": "error",
"@typescript-eslint/no-floating-promises": "error",
"@typescript-eslint/member-delimiter-style": [
"error",
{
"multiline": {
"delimiter": "none",
"requireLast": false
},
"singleline": {
"delimiter": "comma",
"requireLast": false
}
}
],
"no-console": "off",
"react/jsx-filename-extension": [
1,
{
"extensions": [".js", ".jsx", ".ts", ".tsx"]
}
],
"react/jsx-uses-react": 1,
"react/jsx-uses-vars": 1,
"react/prop-types": 0,
"prettier/prettier": 1
}
}