-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy patheslint.config.js
114 lines (113 loc) · 2.19 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
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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
import antfu from '@antfu/eslint-config'
export default antfu({
typescript: true,
astro: true,
yaml: true,
toml: false,
jsonc: false,
markdown: false,
rules: {
'curly': 'off',
'no-unused-vars': 'off',
'no-var': 'error',
'unused-imports/no-unused-imports': 'error',
'style/no-tabs': 'off',
'antfu/if-newline': 'off',
'style/indent': ['error', 'tab'],
'eslint-comments/no-unlimited-disable': 'off',
'style/comma-dangle': ['error', 'always-multiline'],
},
vue: {
overrides: {
'vue/block-order': ['error', {
order: [['script', 'template'], 'style'],
}],
'vue/multi-word-component-names': [
'off',
],
'vue/max-attributes-per-line': 'off',
'vue/static-class-names-order': 'off',
'vue/attribute-hyphenation': 'off',
'vue/html-self-closing': 'off',
'vue/html-indent': ['error', 'tab'],
'vue/no-v-text-v-html-on-component': 'off',
},
},
stylistic: {
overrides: {
'style/brace-style': ['warn', '1tbs'],
'node/prefer-global': 'off',
'node/prefer-global/buffer': 'off',
'antfu/no-import-dist': 'off',
'no-console': 'off',
'style/semi': ['error', 'never'],
'style/comma-dangle': ['error', 'never'],
'style/arrow-parens': 'off',
'style/quotes': [
'error',
'single',
{
allowTemplateLiterals: true,
},
],
'style/brace-style': [
'error',
],
'style/comma-spacing': 'off',
'style/func-call-spacing': 'off',
'prefer-const': [
'error',
{
destructuring: 'all',
ignoreReadBeforeAssign: false,
},
],
'import/order': [
'error',
{
'groups': [
'builtin',
'external',
[
'internal',
],
[
'parent',
'sibling',
],
'index',
'type',
],
'newlines-between': 'always',
'alphabetize': {
order: 'asc',
caseInsensitive: true,
},
'pathGroups': [
{
pattern: 'src/**',
group: 'internal',
position: 'after',
},
],
},
],
'import/no-cycle': [
2,
{
maxDepth: 1,
},
],
'import/newline-after-import': [
'error',
{
count: 1,
},
],
'style/object-curly-spacing': [
2,
'always',
],
},
},
})