-
Notifications
You must be signed in to change notification settings - Fork 1
/
eslint.config.js
32 lines (31 loc) · 1.01 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
import antfu from '@antfu/eslint-config'
export default antfu({
typescript: true,
stylistic: {
indent: 2, // 缩进
quotes: 'single', // 引号
},
rules: {
'no-use-before-define': 'off', // 允许定义之前使用
'no-prototype-builtins': 'off', // 允许使用原型方法
'unused-imports/no-unused-imports': 2, // 防止未使用导入的规则
},
}, {
rules: {
'no-console': 'off',
'node/prefer-global/process': 'off',
'ts/ban-types': 'off',
'ts/method-signature-style': 'off',
'unused-imports/no-unused-vars': 'off',
'array-callback-return': 'off',
'ts/ban-ts-comment': 'off',
'@typescript-eslint/interface-name-prefix': 'off',
'@typescript-eslint/explicit-function-return-type': 'off',
'@typescript-eslint/explicit-module-boundary-types': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'ts/consistent-type-imports': 'off',
'ts/no-require-imports': 'off',
'ts/no-var-requires': 'off',
'import/no-mutable-exports': 'off',
},
})