-
-
Notifications
You must be signed in to change notification settings - Fork 184
/
.eslintrc.js
98 lines (98 loc) · 3.33 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
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
module.exports = {
settings: { version: 'detect' },
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
'plugin:unicorn/recommended',
'xo/browser',
'xo-typescript/space',
'xo-react/space',
'plugin:chai-friendly/recommended',
'plugin:jest/recommended',
'plugin:import/errors',
'plugin:import/warnings',
'plugin:import/typescript',
'prettier',
],
plugins: ['chai-friendly', 'jest', 'import'],
rules: {
'no-multiple-empty-lines': ['error', { max: 1, maxEOF: 0, maxBOF: 0 }],
'no-unused-expressions': 0,
'no-negated-condition': 0,
'no-warning-comments': ['warn', { terms: ['todo'], location: 'start' }],
'operator-assignment': 0,
'import/no-unresolved': 0,
'chai-friendly/no-unused-expressions': 0,
'@typescript-eslint/no-unused-expressions': 0,
'@typescript-eslint/no-use-before-define': 0,
'@typescript-eslint/no-base-to-string': 0,
'@typescript-eslint/prefer-nullish-coalescing': 0,
'@typescript-eslint/no-unsafe-return': 0,
'@typescript-eslint/no-confusing-void-expression': 0,
'@typescript-eslint/no-unsafe-assignment': 0,
'@typescript-eslint/semi': 0,
'@typescript-eslint/restrict-template-expressions': 0,
'@typescript-eslint/default-param-last': 0,
'@typescript-eslint/prefer-optional-chain': 0,
'@typescript-eslint/explicit-module-boundary-types': 0,
'@typescript-eslint/no-var-requires': 0,
'@typescript-eslint/naming-convention': 0,
'@typescript-eslint/no-require-imports': 0,
'@typescript-eslint/no-throw-literal': 0,
'@typescript-eslint/no-implicit-any-catch': 0,
'@typescript-eslint/triple-slash-reference': 0,
'react/prop-types': 0,
'jest/prefer-expect-assertions': 0,
'capitalized-comments': 0,
'comma-dangle': 0,
'import/extensions': ['error', { svg: 'allow' }],
'import/no-unassigned-import': ['error', { allow: ['**/*.css'] }],
'unicorn/filename-case': ['error', { case: 'camelCase' }],
'unicorn/prefer-type-error': 0,
'unicorn/no-reduce': 0,
'unicorn/import-style': 0,
'unicorn/prefer-optional-catch-binding': 0,
'unicorn/no-null': 0,
'unicorn/prevent-abbreviations': 0,
'unicorn/no-array-reduce': 0,
'unicorn/prefer-module': 0,
'unicorn/consistent-destructuring': 0,
'unicorn/prefer-node-protocol': 0,
'unicorn/prefer-array-flat': 0,
'unicorn/prefer-export-from': ['error', { ignoreUsedVariables: true }],
},
overrides: [
{
files: ['**/*.ts', '**/*.js'],
rules: { 'jest/no-try-expect': 0 },
},
{
files: ['**/*.js', '**/*.jsx'],
rules: {
'@typescript-eslint/explicit-function-return-type': 0,
'@typescript-eslint/space-before-function-paren': 0,
'@typescript-eslint/no-unsafe-call': 0,
'@typescript-eslint/no-unsafe-member-access': 0,
'@typescript-eslint/prefer-readonly-parameter-types': 0,
},
},
{
files: ['types/tests/**/*.ts', 'types/tests/**/*.tsx'],
rules: {
'@typescript-eslint/no-unused-vars': 0,
'import/no-unassigned-import': 0,
'@typescript-eslint/no-unsafe-call': 0,
},
},
],
ignorePatterns: [
'.eslintrc.js',
'macro.js',
'types',
'__fixtures__',
'tailwind.config.js',
'sandbox',
'types/macro.d.ts',
],
globals: { JSX: true, AriaAttributes: true },
}