Files
creator-hub/web/vite.config.js
T
rogee 61543a4a61 chore: ignore .codegraph index and allow LAN access for vite dev server
- .gitignore 增加 .codegraph/(本地代码索引,不进版本库)
- vite dev server 开启 host,便于局域网访问本地前端
2026-09-02 17:11:52 +08:00

25 lines
610 B
JavaScript

import { defineConfig } from "vite";
import react from "@vitejs/plugin-react";
import tailwindcss from "@tailwindcss/vite";
export default defineConfig({
plugins: [react(), tailwindcss()],
server: {
host: true,
port: 5173,
strictPort: true,
proxy: { "/api": "http://127.0.0.1:8082" },
},
test: {
environment: "jsdom",
pool: "threads",
maxWorkers: 1,
isolate: false, // ponytail: one worker avoids 90s startup stalls; restore isolation if tests leak state.
coverage: {
provider: "v8",
reporter: ["text"],
thresholds: { lines: 65 },
},
},
});