-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy patheslint.config.ts
92 lines (90 loc) · 1.67 KB
/
eslint.config.ts
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
import {
comments,
defineConfig,
imports,
javascript,
jsonc,
markdown,
prettier,
promise,
regexp,
stylistic,
typescript,
unicorn,
vitest,
vue,
yaml
} from '@kazupon/eslint-config'
import { globalIgnores } from 'eslint/config'
const config: ReturnType<typeof defineConfig> = defineConfig(
javascript(),
stylistic(),
comments({
kazupon: {
ignores: ['./playground/**', './docs/**', './test/**', './src/**.test.ts']
}
}),
imports({
typescript: true,
rules: {
'import/extensions': ['error', 'always', { ignorePackages: true }]
}
}),
promise(),
regexp(),
unicorn({
rules: {
'unicorn/no-array-push-push': 'off',
'unicorn/no-array-reduce': 'off',
'unicorn/prevent-abbreviations': 'off',
'unicorn/filename-case': 'off',
'unicorn/no-null': 'off'
}
}),
typescript({
parserOptions: {
tsconfigRootDir: import.meta.dirname
},
rules: {
'@typescript-eslint/no-empty-object-type': 'off',
'@typescript-eslint/ban-ts-comment': 'off'
}
}),
vue({
parserOptions: {
tsconfigRootDir: import.meta.dirname
},
composable: true,
typescript: true
}),
jsonc({
json: true,
json5: true,
jsonc: true,
prettier: true
}),
yaml({
prettier: true
}),
markdown({
rules: {
'import/extensions': 'off'
}
}),
vitest(),
prettier(),
// @ts-expect-error -- FIXME
globalIgnores([
'.vscode',
'docs/.vitepress/cache',
'docs/.vitepress/config.ts',
'docs/api',
'**/dist/**',
'lib',
'tsconfig.json',
'pnpm-lock.yaml',
'playground/bun',
'playground/deno'
])
)
export default config