-
Notifications
You must be signed in to change notification settings - Fork 0
/
.eslintrc.js
86 lines (82 loc) · 2.68 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
module.exports = {
env: {
browser: true,
es2021: true,
},
extends: [
'airbnb',
'eslint:recommended',
'plugin:react/recommended',
'plugin:react-hooks/recommended',
'plugin:@typescript-eslint/recommended',
'plugin:storybook/recommended',
],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 'latest',
sourceType: 'module',
},
plugins: ['@typescript-eslint', '@tanstack/query', 'simple-import-sort', 'import'],
rules: {
'arrow-parens': 'off',
'no-shadow': 'off',
'no-use-before-define': 'off',
'implicit-arrow-linebreak': 'off',
'operator-linebreak': 'off',
'object-curly-newline': 'off',
'function-paren-newline': 'off',
'no-extra-boolean-cast': 'off',
'no-confusing-arrow': 'off',
'no-unused-expressions': 'off',
'no-alert': 'off',
'no-restricted-globals': 'off',
'react/prop-types': 'off',
'consistent-return': 'off',
'prefer-destructuring': 'off',
'no-nested-ternary': 'off',
'no-underscore-dangle': 'off',
indent: 'off',
'react/jsx-props-no-spreading': 'off',
'react/react-in-jsx-scope': 'off',
'react/require-default-props': 'off',
'react/function-component-definition': [2, { namedComponents: 'arrow-function' }],
'react/jsx-filename-extension': [2, { extensions: ['.js', '.jsx', '.ts', '.tsx'] }],
'react/jsx-one-expression-per-line': 'off',
'react/no-unknown-property': ['error', { ignore: ['css'] }],
'react/jsx-wrap-multilines': 'off',
'react/no-array-index-key': 'off',
'react/destructuring-assignment': 'off',
'react/jsx-curly-newline': 'off',
'react/no-unused-prop-types': 'off',
'jsx-a11y/click-events-have-key-events': 'warn',
'jsx-a11y/interactive-supports-focus': 'warn',
'jsx-a11y/no-static-element-interactions': 'warn',
'@typescript-eslint/ban-ts-comment': 'off',
'@typescript-eslint/no-unused-vars': 'warn',
'@typescript-eslint/no-unused-expressions': 'off',
'@typescript-eslint/consistent-type-imports': 'error',
'simple-import-sort/imports': 'error',
'simple-import-sort/exports': 'error',
'import/prefer-default-export': 'off',
'import/first': 'error',
'import/newline-after-import': 'error',
'import/no-duplicates': 'error',
'import/no-unresolved': 'off',
'import/no-extraneous-dependencies': ['error', { devDependencies: true }],
'import/extensions': [
'error',
{
js: 'never',
jsx: 'never',
types: 'always',
styles: 'always',
ts: 'never',
tsx: 'never',
svg: 'always',
png: 'always',
webp: 'always',
},
],
},
ignorePatterns: ['config', 'dist', '*.config.*'],
};