Configure ESLint 10 (flat, Vue + a11y), Prettier, Vitest + @vue/test-utils + jsdom, and add npm scripts for lint/format/test. Document VITE_API_BASE_URL.
30 lines
800 B
JavaScript
30 lines
800 B
JavaScript
import js from '@eslint/js'
|
|
import prettier from 'eslint-config-prettier'
|
|
import pluginVue from 'eslint-plugin-vue'
|
|
import vueA11y from 'eslint-plugin-vuejs-accessibility'
|
|
import globals from 'globals'
|
|
import tseslint from 'typescript-eslint'
|
|
|
|
export default tseslint.config(
|
|
{ ignores: ['dist/**', 'node_modules/**', 'coverage/**'] },
|
|
js.configs.recommended,
|
|
...tseslint.configs.recommended,
|
|
...pluginVue.configs['flat/recommended'],
|
|
...vueA11y.configs['flat/recommended'],
|
|
{
|
|
files: ['**/*.{ts,vue}'],
|
|
languageOptions: {
|
|
globals: { ...globals.browser },
|
|
parserOptions: {
|
|
parser: tseslint.parser,
|
|
ecmaVersion: 'latest',
|
|
sourceType: 'module',
|
|
},
|
|
},
|
|
rules: {
|
|
'vue/multi-word-component-names': 'off',
|
|
},
|
|
},
|
|
prettier,
|
|
)
|