All checks were successful
Deploy Admin Frontend / build-and-deploy (push) Successful in 13s
## 类型安全 - tsconfig: 开启 strict: true(豁免 noImplicitAny + strictNullChecks,待后续收紧) - 新建 15 个领域类型文件 (src/types/),共 ~80 个类型定义 - 统一 barrel export (src/types/index.ts) - 消除 9 个 [key: string]: any 接口 - 消除 22 个 API data: any 参数 → 替换为具体 DTO - 消除 36 个 Promise<any> → 使用具体泛型 - 消除重复 PaginatedResponse,统一使用 PaginatedResult - API 内联类型全部迁至 types/ ## 状态管理 - 引入 Zustand (zustand + persist) - 新建 src/stores/ui-store.ts — 侧边栏折叠状态持久化 - AdminLayout 接入 useUIStore ## 环境配置 - 新建 .env.example — 环境变量模板 - 新建 .env.production — 生产架构文档 - 新建 src/vite-env.d.ts — IDE 类型声明 ## 通用 UI 类型 - 新建 src/types/ui.ts — TypedColumn<T>, SortState, FilterState 等 Co-Authored-By: Claude <noreply@anthropic.com>
14 lines
493 B
Plaintext
14 lines
493 B
Plaintext
# ============================================
|
||
# 知习 Admin 前端 — 环境变量
|
||
# ============================================
|
||
# 复制此文件为 .env 用于本地开发
|
||
# cp .env.example .env
|
||
#
|
||
# 生产环境:不需要配置,Nginx 自动代理 API 请求
|
||
# ============================================
|
||
|
||
# API 后端地址(仅本地开发使用)
|
||
# - 本地开发:http://127.0.0.1:3000
|
||
# - 连接远程 API:https://api.longde.cloud
|
||
VITE_API_BASE_URL=http://127.0.0.1:3000
|