-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patheslint.config.mjs
35 lines (34 loc) · 1.07 KB
/
eslint.config.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
import js from '@eslint/js'
import eslintPluginVue from 'eslint-plugin-vue'
import tseslint from 'typescript-eslint'
import eslintConfigPrettier from "eslint-config-prettier";
export default tseslint.config(
js.configs.recommended,
...tseslint.configs.recommendedTypeChecked,
...eslintPluginVue.configs['flat/recommended'],
eslintConfigPrettier,
{
files: ['**/*.{vue,js,jsx,cjs,mjs,ts,tsx,cts,mts}'],
ignores: ['node_modules/', '.git/', '**/dist/*', '**/build/*'],
languageOptions: {
ecmaVersion: "latest",
sourceType: "script",
parserOptions: {
parser: tseslint.parser,
projectService: true,
tsconfigRootDir: import.meta.dirname,
extraFileExtensions: ['.vue'],
}
},
rules: {
"@typescript-eslint/restrict-template-expressions": "off",
"vue/attribute-hyphenation": ["error", "never"],
"vue/v-on-event-hyphenation": ["error", "never"],
"vue/custom-event-name-casing": ["error", "camelCase"],
}
},
{
files: ['**/*.mjs'],
...tseslint.configs.disableTypeChecked,
},
)