-
Notifications
You must be signed in to change notification settings - Fork 1
/
eslint.base.mjs
36 lines (35 loc) · 1.05 KB
/
eslint.base.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
import { fileURLToPath } from 'url'
import { dirname } from 'path'
export default {
dirname: (importMetaUrl) => {
const __filename = fileURLToPath(importMetaUrl)
return dirname(__filename)
},
rules: [
{
rules: {
'semi': ['error', 'never'],
'quotes': ['error', 'single', {
avoidEscape: true,
allowTemplateLiterals: true,
}],
'comma-dangle': ['error', 'always-multiline'],
'no-void': ['error', { allowAsStatement: true }],
'require-await': 'error',
'space-infix-ops': 'error',
'@typescript-eslint/no-floating-promises': ['error', { ignoreVoid: true }],
'@typescript-eslint/no-inferrable-types': 'off',
'@typescript-eslint/ban-ts-comment': 'off',
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-unused-vars': [
'warn',
{
argsIgnorePattern: '^_',
varsIgnorePattern: '(^log$|^_)',
},
],
'vue/multi-word-component-names': 'off',
},
},
],
}