forked from A-kirami/matcha
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintrc.json
140 lines (140 loc) · 3.95 KB
/
.eslintrc.json
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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
{
"env": {
"browser": true,
"es2021": true,
"node": true
},
"extends": [
"eslint-config-prettier",
"eslint:recommended",
"plugin:vue/vue3-recommended",
"plugin:import/recommended",
"plugin:import/typescript",
"plugin:@typescript-eslint/recommended",
"plugin:promise/recommended",
"plugin:prettier/recommended",
"@unocss"
],
"parserOptions": {
"ecmaVersion": 13,
"parser": "@typescript-eslint/parser",
"sourceType": "module"
},
"plugins": ["vue", "@typescript-eslint"],
"parser": "vue-eslint-parser",
"globals": {
"defineProps": "readonly",
"defineEmits": "readonly",
"defineExpose": "readonly",
"withDefaults": "readonly",
"$ref": "readonly",
"$computed": "readonly",
"$shallowRef": "readonly",
"$customRef": "readonly",
"$toRef": "readonly",
"$": "readonly",
"$$": "readonly"
},
"rules": {
"linebreak-style": ["warn", "windows"],
"quotes": ["warn", "single"],
"semi": ["warn", "never"],
"object-shorthand": ["warn", "always"],
"array-bracket-spacing": [
"warn",
"never",
{
"objectsInArrays": false,
"arraysInArrays": false
}
],
"object-curly-spacing": ["warn", "always"],
"array-callback-return": "error",
"arrow-spacing": "warn",
"block-scoped-var": "error",
"block-spacing": "warn",
"brace-style": ["error", "1tbs"],
"camelcase": "error",
"comma-spacing": [
"error",
{
"before": false,
"after": true
}
],
"comma-style": ["error", "last"],
"computed-property-spacing": ["error", "never"],
"consistent-this": ["error", "that"],
"constructor-super": "error",
"curly": "error",
"default-case": "error",
"dot-location": ["error", "property"],
"dot-notation": "error",
"eol-last": ["warn", "always"],
"eqeqeq": ["error", "always"],
"for-direction": "error",
"func-names": ["warn", "as-needed"],
"function-paren-newline": ["warn", "multiline-arguments"],
"getter-return": ["error", { "allowImplicit": true }],
"guard-for-in": "error",
"implicit-arrow-linebreak": ["warn", "beside"],
"key-spacing": [
"error",
{
"beforeColon": false,
"afterColon": true
}
],
"keyword-spacing": [
"error",
{
"before": true,
"after": true
}
],
"space-infix-ops": "warn",
"space-unary-ops": ["warn", { "nonwords": false }],
"new-cap": "warn",
"no-await-in-loop": "error",
"no-cond-assign": "error",
"no-empty": "warn",
"no-constant-condition": "error",
"no-var": "error",
"spaced-comment": ["warn", "always", { "markers": ["/"] }],
"no-console": "warn",
"accessor-pairs": "error",
"no-alert": "warn",
"no-eval": "error",
"no-trailing-spaces": "warn",
"no-inline-comments": "warn",
// "lines-around-comment": ["warn", {"allowBlockStart": true, "allowObjectStart": true, "allowArrayStart": true, "allowClassStart": true}],
"@typescript-eslint/no-var-requires": "off",
"@typescript-eslint/no-non-null-assertion": "off",
"vue/no-multiple-template-root": "off",
"vue/no-v-model-argument": "off",
"vue/no-v-for-template-key": "off",
"vue/script-setup-uses-vars": "error",
"vue/multi-word-component-names": "off",
"vue/no-setup-props-destructure": "off",
"import/no-unresolved": ["error", { "ignore": ["^virtual:", "\\.png$"] }],
"import/order": [
"warn",
{
"groups": ["builtin", "external", "internal", ["parent", "sibling", "index"], "type"],
"newlines-between": "always",
"alphabetize": { "order": "asc", "caseInsensitive": true }
}
],
"import/newline-after-import": ["warn", { "considerComments": true }]
},
"settings": {
"import/parsers": {
"@typescript-eslint/parser": [".ts", ".tsx"]
},
"import/resolver": {
"typescript": {
"alwaysTryTypes": true
}
}
}
}