forked from ICIJ/murmur
-
Notifications
You must be signed in to change notification settings - Fork 0
/
eslint.config.js
51 lines (49 loc) · 1.27 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
44
45
46
47
48
49
50
51
import tsParser from '@typescript-eslint/parser';
import tsConfigs from '@typescript-eslint/eslint-plugin';
import vitestPlugin from 'eslint-plugin-vitest';
import storybookPlugin from 'eslint-plugin-storybook';
import icijPlugin from '@icij/eslint-config';
export default [
{
files: ['**/*.{ts,tsx}'],
ignores: ['tmpDoc/**/*.stories.{ts,tsx}'],
languageOptions: {
parser: tsParser,
parserOptions: {
ecmaVersion: 2021,
sourceType: 'module'
},
},
plugins: {
'@typescript-eslint': tsConfigs,
vitest: vitestPlugin,
storybook: storybookPlugin,
icij: icijPlugin,
},
rules: {
...tsConfigs.configs.recommended.rules,
...vitestPlugin.configs.recommended.rules,
...storybookPlugin.configs.recommended.rules,
...icijPlugin.rules,
'@typescript-eslint/no-explicit-any': 'off',
'vitest/no-identical-title': 'error',
'vitest/expect-expect': 'error',
"import/no-named-default": "off",
},
},
{
files: ['*.stories.ts', '*.stories.tsx'],
rules: {
'storybook/no-stories-of': 'warn',
'storybook/prefer-csf': 'warn',
},
},
{
files: ['*spec.ts', '*spec.tsx'],
languageOptions: {
globals: {
vitest: true,
},
},
},
];