chore: vite 固定 5175,脚本统一 --cwd,清理未用导入
This commit is contained in:
@@ -26,7 +26,6 @@ Bun 工具链(选型见 `docs/design/技术选型.md`)。**Windows 上 `bun`
|
||||
| 命令 | 用途 |
|
||||
|------|------|
|
||||
| `bun install` | 安装 / 链接 workspace 依赖(在仓库根) |
|
||||
| `bun test` | 全部测试(core 契约 + server HTTP + **集成**);集成需 `DATABASE_URL`(compose 中的 PG),无库时自动跳过 |
|
||||
| `bun run db:generate` | 生成 SQL 迁移(`packages/db/drizzle/`) |
|
||||
| `bun run db:push` | 推送到本地库(开发期) |
|
||||
| `bun run db:studio` | Drizzle Studio 看库 |
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
/**
|
||||
* 订阅选择弹层:登录(仅一次/标签页)+ 列表选用,与登记表单解耦
|
||||
*/
|
||||
import { computed, ref, watch } from "vue";
|
||||
import { ref, watch } from "vue";
|
||||
import {
|
||||
listPlatformSubscriptions,
|
||||
loginPlatform,
|
||||
|
||||
@@ -11,7 +11,7 @@ import TimeRangePicker from "@/components/common/time-range-picker.vue";
|
||||
import QuotaText from "@/components/common/quota-text.vue";
|
||||
import { useLiveTimeRange } from "@/composables/use-live-time-range.ts";
|
||||
import { useAdminLogs, useKeys, useMembers } from "@/queries/admin.ts";
|
||||
import { formatDateTime, recentDaysRange } from "@/utils/time.ts";
|
||||
import { formatDateTime } from "@/utils/time.ts";
|
||||
import { formatInt } from "@/utils/format.ts";
|
||||
|
||||
const route = useRoute();
|
||||
|
||||
@@ -17,6 +17,9 @@ export default defineConfig({
|
||||
},
|
||||
},
|
||||
server: {
|
||||
// 固定开发口:避免在 5173/5174 被占时静默跳到 5175(strictPort 不自动改口)
|
||||
port: 5175,
|
||||
strictPort: true,
|
||||
proxy: {
|
||||
// 契约:/api/* 专属接口;SPA 路由不进 /api(公共约定 §2)
|
||||
"/api": {
|
||||
|
||||
+5
-1
@@ -8,7 +8,11 @@
|
||||
"typecheck": "tsc -p tsconfig.json --noEmit",
|
||||
"dev:server": "bun --hot --env-file=.env apps/server/src/index.ts",
|
||||
"dev:engine": "bun --env-file=.env apps/engine/src/index.ts",
|
||||
"dev:web": "bun --filter @new-api-key-usage/web dev"
|
||||
"dev:web": "bun run --cwd apps/web dev",
|
||||
"db:generate": "bun run --cwd packages/db db:generate",
|
||||
"db:push": "bun run --cwd packages/db db:push",
|
||||
"db:studio": "bun run --cwd packages/db db:studio",
|
||||
"build:web": "bun run --cwd apps/web build"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/bun": "^1.4.2",
|
||||
|
||||
Reference in New Issue
Block a user