- 添加 .editorconfig, .gitignore, .prettierrc.json 等配置文件 - 创建项目目录结构,包括 src, test 等文件夹 - 添加 Vue 3 和 Vite 相关依赖 - 配置 ESLint, Prettier 等代码规范工具 - 添加 README.md 文件,说明项目的基本信息和操作指南
28 lines
687 B
JavaScript
28 lines
687 B
JavaScript
import pluginVue from 'eslint-plugin-vue'
|
|
import vueTsEslintConfig from '@vue/eslint-config-typescript'
|
|
import pluginVitest from '@vitest/eslint-plugin'
|
|
import oxlint from 'eslint-plugin-oxlint'
|
|
import skipFormatting from '@vue/eslint-config-prettier/skip-formatting'
|
|
|
|
export default [
|
|
{
|
|
name: 'app/files-to-lint',
|
|
files: ['**/*.{ts,mts,tsx,vue}'],
|
|
},
|
|
|
|
{
|
|
name: 'app/files-to-ignore',
|
|
ignores: ['**/dist/**', '**/dist-ssr/**', '**/coverage/**'],
|
|
},
|
|
|
|
...pluginVue.configs['flat/essential'],
|
|
...vueTsEslintConfig(),
|
|
|
|
{
|
|
...pluginVitest.configs.recommended,
|
|
files: ['src/**/__tests__/*'],
|
|
},
|
|
oxlint.configs['flat/recommended'],
|
|
skipFormatting,
|
|
]
|