-
Notifications
You must be signed in to change notification settings - Fork 0
/
eslint.config.js
43 lines (41 loc) · 1.11 KB
/
eslint.config.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
import sheriff from 'eslint-config-sheriff';
import { defineFlatConfig } from 'eslint-define-config';
import * as pluginReactQuery from '@tanstack/eslint-plugin-query';
/**
* @type {import('@sherifforg/types').SheriffSettings}
*/
const sheriffOptions = {
files: ['**/*.{ts,tsx}'],
pathsOveriddes: {
tsconfigLocation: ['./tsconfig.json', './tsconfig.node.json'],
},
ignores: {
inheritedFromGitIgnore: true,
recommended: true,
},
react: true,
lodash: true,
vitest: true,
};
export default defineFlatConfig([
...sheriff(sheriffOptions),
{
plugins: {
'@tanstack/query': pluginReactQuery,
},
rules: {
...pluginReactQuery.configs.recommended.rules,
'react/no-multi-comp': 'off',
'@typescript-eslint/explicit-module-boundary-types': 'off',
'@typescript-eslint/no-confusing-void-expression': [
'error',
{
ignoreArrowShorthand: true,
},
],
'@typescript-eslint/consistent-type-definitions': ['error', 'type'],
'import/no-named-as-default': 'off',
'arrow-return-style/arrow-return-style': 'off',
},
},
]);