-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheslint.config.ts
More file actions
69 lines (66 loc) · 1.96 KB
/
eslint.config.ts
File metadata and controls
69 lines (66 loc) · 1.96 KB
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
import eslint from "@eslint/js"
import tseslint from "typescript-eslint"
import pluginVue from "eslint-plugin-vue"
import eslintConfigPrettier from "eslint-config-prettier"
export default tseslint.config(
{
ignores: ["dist/**", "node_modules/**", "vendor/**", "public/**", "docs/**", "**/*.d.ts"],
},
eslint.configs.recommended,
...tseslint.configs.recommended,
...pluginVue.configs["flat/recommended"],
{
files: ["**/*.vue"],
languageOptions: {
parserOptions: {
parser: tseslint.parser,
},
},
},
eslintConfigPrettier,
{
rules: {
"vue/block-order": [
"error",
{
order: ["script", "template", "style"],
},
],
"vue/multi-word-component-names": "off",
"vue/component-api-style": ["error", ["script-setup", "composition"]],
"vue/component-name-in-template-casing": "error",
"vue/block-lang": [
"error",
{
script: { lang: "ts" },
},
],
"vue/define-macros-order": [
"warn",
{
order: ["defineProps", "defineEmits"],
},
],
"vue/define-emits-declaration": ["error", "type-based"],
"vue/define-props-declaration": ["error", "type-based"],
"vue/match-component-import-name": "error",
"vue/no-unused-refs": "error",
"vue/no-useless-v-bind": "error",
"vue/padding-line-between-tags": "warn",
"vue/no-v-html": "off",
"vue/require-default-prop": "off",
"vue/valid-v-slot": "off",
"no-undef": "off",
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/no-explicit-any": "off",
"no-console": ["warn"],
"no-prototype-builtins": "off",
// sticking to the team's rules
"vue/prefer-separate-static-class": "off",
"vue/no-reserved-component-names": "off",
"vue/no-setup-props-destructure": "off",
"vue/prefer-true-attribute-shorthand": "off",
},
}
)