53 lines
1.1 KiB
JavaScript
53 lines
1.1 KiB
JavaScript
import eslint from '@eslint/js'
|
|
import eslintConfigPrettier from 'eslint-config-prettier'
|
|
import eslintPluginVue from 'eslint-plugin-vue'
|
|
import globals from 'globals'
|
|
import tseslint from 'typescript-eslint'
|
|
|
|
export default tseslint.config(
|
|
{
|
|
ignores: ['**/dist/**', '**/node_modules/**', '**/coverage/**', '**/*.d.ts'],
|
|
},
|
|
eslint.configs.recommended,
|
|
...tseslint.configs.recommended,
|
|
...eslintPluginVue.configs['flat/recommended'],
|
|
{
|
|
files: ['**/*.{ts,tsx,vue}'],
|
|
languageOptions: {
|
|
globals: globals.browser,
|
|
parserOptions: {
|
|
parser: tseslint.parser,
|
|
},
|
|
},
|
|
},
|
|
{
|
|
files: ['**/*.{js,mjs,cjs}'],
|
|
languageOptions: {
|
|
globals: globals.node,
|
|
},
|
|
},
|
|
{
|
|
files: ['vite.config.ts', '*.config.{js,mjs,cjs,ts}'],
|
|
languageOptions: {
|
|
globals: globals.node,
|
|
},
|
|
},
|
|
{
|
|
files: ['**/*.vue'],
|
|
languageOptions: {
|
|
parserOptions: {
|
|
parser: tseslint.parser,
|
|
},
|
|
},
|
|
rules: {
|
|
'vue/multi-word-component-names': 'off',
|
|
},
|
|
},
|
|
{
|
|
rules: {
|
|
'@typescript-eslint/no-explicit-any': 'warn',
|
|
},
|
|
},
|
|
eslintConfigPrettier,
|
|
)
|