-
Notifications
You must be signed in to change notification settings - Fork 20
/
.eslintrc.js
49 lines (43 loc) · 1.91 KB
/
.eslintrc.js
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
module.exports = {
extends: ['@salutejs/eslint-config'],
rules: {
camelcase: 'warn',
'no-irregular-whitespace': 'warn',
'no-restricted-imports': 'warn', // NOTE: https://eslint.org/docs/latest/rules/no-restricted-imports
radix: 'warn',
'no-use-before-define': 'off',
'padding-line-between-statements': 'off',
'space-before-function-paren': [
'warn',
{
anonymous: 'never',
named: 'never',
asyncArrow: 'always',
},
], // NOTE: https://eslint.org/docs/latest/rules/space-before-function-paren
'react/jsx-wrap-multilines': 'off', // NOTE: https://github.com/jsx-eslint/eslint-plugin-react/blob/master/docs/rules/jsx-wrap-multilines.md
'react/jsx-closing-tag-location': 'off', // NOTE: https://github.com/jsx-eslint/eslint-plugin-react/blob/master/docs/rules/jsx-closing-tag-location.md
'react/jsx-no-leaked-render': 'off',
'react/display-name': 'off', // NOTE: https://github.com/jsx-eslint/eslint-plugin-react/blob/master/docs/rules/display-name.md
'react/require-default-props': 'off',
'react/no-unused-prop-types': 'off',
'react-hooks/exhaustive-deps': 'off', // TODO: вернуть на warn, а затем https://github.com/salute-developers/plasma/issues/160
'@typescript-eslint/no-unnecessary-type-constraint': 'warn',
'@typescript-eslint/ban-types': [
'warn',
{
extendDefaults: true,
types: {
'{}': false,
object: false,
},
},
], // NOTE: If you want a type meaning "empty object", you probably want `Record<string, never>` instead
'@typescript-eslint/no-empty-interface': 'off',
},
settings: {
react: {
version: 'detect',
},
},
};