fix: eslint error

This commit is contained in:
2025-09-19 12:00:35 +08:00
parent 560367eeb5
commit 86a8d00991
5 changed files with 33 additions and 23 deletions

View File

@@ -1,7 +1,7 @@
import {defineConfig} from "vite";
import react from "@vitejs/plugin-react-swc";
import tsconfigPaths from "vite-tsconfig-paths";
import checker from "vite-plugin-checker";
import react from '@vitejs/plugin-react-swc'
import { defineConfig } from 'vite'
import checker from 'vite-plugin-checker'
import tsconfigPaths from 'vite-tsconfig-paths'
// https://vite.dev/config/
export default defineConfig({
@@ -9,9 +9,11 @@ export default defineConfig({
react(),
tsconfigPaths(),
checker({
typescript: true, // 开启 TypeScript 检查
typescript: true,
eslint: {
lintCommand: "eslint \"./src/**/*.{ts,tsx}\"", // 自定义 eslint 命令
lintCommand: 'eslint "./src/**/*.{ts,tsx}"',
useFlatConfig: true,
},
})],
});
}),
],
})