forked from AxaFrance/react-toolkit
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc
102 lines (78 loc) · 4.06 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
{
"parser": "@typescript-eslint/parser",
"env": {
"browser": true,
"node": true,
"es6": true,
"jest": true
},
"extends": [
"airbnb-typescript",
"react-app",
"prettier",
"prettier/@typescript-eslint",
"prettier/react"
],
"parserOptions": {
"project": "./tsconfig.json"
},
"plugins": ["react", "prettier"],
"rules": {
// https://github.com/eslint/eslint/blob/master/docs/rules/no-param-reassign.md
"no-param-reassign": "warn",
// https://github.com/eslint/eslint/blob/master/docs/rules/no-prototype-builtins.md
"no-prototype-builtins": "warn",
// https://github.com/benmosher/eslint-plugin-import/blob/master/docs/rules/no-extraneous-dependencies.md
"import/no-extraneous-dependencies": "off",
// https://github.com/benmosher/eslint-plugin-import/blob/master/docs/rules/no-named-as-default.md
"import/no-named-as-default": "warn",
// https://github.com/benmosher/eslint-plugin-import/blob/master/docs/rules/no-unresolved.md
"import/no-unresolved": "off",
// https://github.com/benmosher/eslint-plugin-import/blob/master/docs/rules/prefer-default-export.md
"import/prefer-default-export": "off",
// https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/master/docs/rules/anchor-is-valid.md
"jsx-a11y/anchor-is-valid": "warn",
// https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/master/docs/rules/aria-role.md
"jsx-a11y/aria-role": "warn",
// https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/blob/master/docs/rules/control-has-associated-label.md
"jsx-a11y/control-has-associated-label": "warn",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/button-has-type.md
"react/button-has-type": "warn",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/destructuring-assignment.md
"react/destructuring-assignment": "warn",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/forbid-foreign-prop-types.md
"react/forbid-foreign-prop-types": "off",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/jsx-filename-extension.md
"react/jsx-filename-extension": [
2,
{
"extensions": [".js", ".jsx", ".tsx"]
}
],
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/forbid-prop-types.md
"react/forbid-prop-types": "off",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/jsx-closing-bracket-location.md
"react/jsx-closing-bracket-location": "off",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/jsx-closing-tag-location.md
"react/jsx-closing-tag-location": "off",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/jsx-props-no-spreading.md
"react/jsx-props-no-spreading": "off",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/no-multi-comp.md
"react/no-multi-comp": "off",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/no-unused-prop-types.md
"react/no-unused-prop-types": "warn",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/no-array-index-key.md
"react/no-array-index-key": "warn",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/no-unescaped-entities.md
"react/no-unescaped-entities": "warn",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/prop-types.md
"react/prop-types": "off",
// https://github.com/yannickcr/eslint-plugin-react/blob/master/docs/rules/require-default-props.md
"react/require-default-props": "off",
// https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-unused-vars.md
"@typescript-eslint/no-unused-vars": "warn",
// https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/no-use-before-define.md
"no-use-before-define": "off",
"@typescript-eslint/no-use-before-define": "error"
}
}