-
Notifications
You must be signed in to change notification settings - Fork 5
/
eslint.config.mjs
53 lines (51 loc) · 1022 Bytes
/
eslint.config.mjs
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
// @ts-check
import js from '@eslint/js';
import jest from 'eslint-plugin-jest';
import tseslint from 'typescript-eslint';
/**
* @type {import("eslint").FlatConfig[]}
*/
const config = [
{
ignores: [
'.idea',
'.yarn',
'.pnp.cjs',
'.pnp.loader.mjs',
'examples/src/',
'**/lib/',
'packages/typoas-react-query/src/__tests__/sample-client.ts',
],
},
js.configs.recommended,
{
languageOptions: {
globals: {
console: 'readonly',
process: 'readonly',
module: 'readonly',
},
},
},
...tseslint.configs.recommendedTypeChecked,
{
languageOptions: {
parserOptions: {
projectService: true,
tsconfigRootDir: import.meta.dirname,
},
},
},
{
files: ['**/*.{js,mjs,cjs}'],
...tseslint.configs.disableTypeChecked,
},
{
files: ['**/__tests__/**/*'],
...jest.configs['flat/recommended'],
settings: {
jest: { version: 29 },
},
},
];
export default config;