-
Notifications
You must be signed in to change notification settings - Fork 114
/
Copy path.eslintrc
88 lines (87 loc) · 2.22 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
{
"root": true,
"extends": [
"standard",
"plugin:react/recommended"
],
"rules": {
"semi": ["error", "always"],
"no-use-before-define": "off",
"no-case-declarations": "off"
},
"globals": {
"Application": true,
"angular": true,
"Fablab": true,
"moment": true,
"_": true,
"Humanize": true,
"GTM": true,
"$": true,
"KeyboardEvent": true
},
"plugins": ["html-erb", "fabmanager"],
"overrides": [
{
"files": ["**/*.ts", "**/*.tsx"],
"env": { "browser": true, "es6": true },
"extends": [
"plugin:react/recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaFeatures": { "jsx": true },
"ecmaVersion": 2018,
"sourceType": "module",
"project": "./tsconfig.json"
},
"plugins": ["@typescript-eslint", "react"],
"rules": {
"react/prop-types": "off",
"react/jsx-uses-react": "off",
"react/react-in-jsx-scope": "off"
}
},
{
"files": ["app/frontend/src/javascript/components/**/*.tsx"],
"rules": {
"import/no-default-export": "error",
"import/no-unused-modules": "error",
"fabmanager/component-class-named-as-component": ["error", { "ignoreAbstractKeyword": true }],
"fabmanager/component-named-like-file": "error",
"fabmanager/component-documentation": "warn",
"fabmanager/component-methods-documentation": "warn",
"fabmanager/no-bootstrap": "error",
"fabmanager/no-utilities": "error",
"fabmanager/scoped-translation": ["error", { "ignoreAbstractKeyword": false }]
}
},
{
"files": ["app/frontend/src/javascript/models/**/*.ts"],
"rules": {
"camelcase": "off"
}
},
{
"files": ["test/**/*"],
"plugins": ["jest"],
"env": {
"jest/globals": true
},
"globals": {
"Range": true,
"Document": true
},
"parserOptions": {
"project": "./test/frontend/tsconfig.json"
}
}
],
"settings": {
"react": {
"version": "detect"
}
}
}