forked from grommet/grommet
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc
105 lines (105 loc) · 2.58 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
{
"parser": "@babel/eslint-parser",
"extends": ["airbnb", "prettier"],
"plugins": ["prettier", "react-hooks", "testing-library"],
"env": {
"node": true,
"es6": true
},
"globals": {
"it": true,
"expect": true,
"describe": true,
"jest": true,
"document": true,
"test": true,
"window": true,
"fetch": true,
"WebSocket": true,
"alert": true,
"URLSearchParams": true,
"defaultProps": true,
"childContextTypes": true,
"contextTypes": true,
"state": true,
"Event": true,
"fail": true,
"afterEach": true,
"beforeEach": true,
"afterAll": true,
"KeyboardEvent": true,
"MouseEvent": true,
"requestAnimationFrame": true,
"ShadowRoot": true
},
"rules": {
"default-param-last": 0,
"import/prefer-default-export": 0,
"indent": "off",
"comma-dangle": ["error", "always-multiline"],
"max-len": [2, { "ignoreUrls": true, "ignoreRegExpLiterals": true }],
"no-console": 0,
"no-restricted-imports": [
"error",
{
"paths": [
{
"name": "react",
"importNames": ["useLayoutEffect"],
"message": "Please import from use-isomorphic-layout-effect instead."
}
]
}
],
"no-useless-concat": 0,
"react/destructuring-assignment": 0,
"react/function-component-definition": 0,
"react/jsx-curly-newline": 0,
"react/jsx-filename-extension": 0,
"react/jsx-indent": 0,
"react/jsx-one-expression-per-line": 0,
"react/jsx-props-no-spreading": 0,
"react/jsx-wrap-multilines": 0,
"react/prop-types": 0,
"react/require-default-props": [
"error",
{
"functions": "ignore"
}
],
"react/sort-comp": 0,
"react/state-in-constructor": 0,
"react/static-property-placement": 0,
"react-hooks/exhaustive-deps": 2,
"react-hooks/rules-of-hooks": 2,
"semi": [2, "always"]
},
"overrides": [
{
"files": ["doc.js", "prop-types.js", "router.js"],
"rules": {
"import/no-extraneous-dependencies": 0
}
},
{
"files": ["*.stories.js", "**/stories/**"],
"rules": {
"import/no-unresolved": 0,
"import/extensions": 0,
"import/no-extraneous-dependencies": 0,
"react/no-multi-comp": 0,
"react/no-unstable-nested-components": 0
}
},
{
"files": ["anchor.stories.js"],
"rules": {
"react/jsx-one-expression-per-line": 0
}
},
{
"files": ["**/Accordion/__tests__/**.tsx"],
"extends": ["plugin:testing-library/react"]
}
]
}