This repository has been archived by the owner on Jan 16, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.cjs
92 lines (91 loc) · 2.38 KB
/
.eslintrc.cjs
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
const rules = {
'@typescript-eslint/ban-ts-comment': [
'error',
{ 'ts-ignore': 'allow-with-description' },
],
'@typescript-eslint/comma-dangle': ['error', 'always-multiline'],
'@typescript-eslint/lines-between-class-members': 'off',
'@typescript-eslint/naming-convention': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-unused-vars': [
'error',
{ argsIgnorePattern: '^_.+', varsIgnorePattern: '^_.+' },
],
'@typescript-eslint/no-var-requires': 'warn',
'@typescript-eslint/quotes': ['error', 'single'],
'@typescript-eslint/restrict-template-expressions': 'off',
camelcase: 'off',
'comma-dangle': ['error', 'always-multiline'],
'global-require': 'off',
'import/no-cycle': 'off',
'import/export': 'off',
'import/extensions': 'off',
'import/no-extraneous-dependencies': 'off',
'import/no-named-as-default': 'off',
'import/no-named-as-default-member': 'off',
'import/order': 'off',
'import/prefer-default-export': 'off',
'max-len': 'warn',
'no-await-in-loop': 'off',
'no-console': 'off',
'no-restricted-exports': 'off',
'no-restricted-syntax': 'off',
'no-underscore-dangle': 'off',
'no-unused-vars': 'off',
quotes: ['error', 'single'],
'react/jsx-filename-extension': [
'error',
{ extensions: ['.js', '.jsx', '.tsx'] },
],
'react/jsx-props-no-spreading': 'off',
'react/no-array-index-key': 'off',
'react/prop-types': 'off',
'react/react-in-jsx-scope': 'off',
'react/require-default-props': 'off',
'simple-import-sort/imports': 'error',
'simple-import-sort/exports': 'error',
};
/** @type {import('eslint').Linter.Config} */
module.exports = {
parser: '@typescript-eslint/parser',
parserOptions: {
project: 'tsconfig.json',
},
extends: [
'airbnb',
'airbnb-typescript',
'airbnb/hooks',
'plugin:@typescript-eslint/recommended',
'plugin:import/typescript',
'plugin:jsx-a11y/recommended',
'plugin:react/recommended',
'plugin:react-hooks/recommended',
],
plugins: [
'simple-import-sort',
],
ignorePatterns: [
'**/node_modules',
'**/dist',
'**/build',
'**/tmp',
],
rules,
env: {
es2022: true,
node: true,
browser: true,
jest: true,
},
settings: {
'import/resolver': {
node: {
extensions: ['.js', '.jsx', '.ts', '.tsx'],
},
typescript: {},
},
},
globals: {
Logger: true,
},
};