refactor: flatten monorepo into standalone project

This commit is contained in:
2026-04-01 19:43:21 +08:00
parent 036afb8d20
commit cd7b65fda4
68 changed files with 339 additions and 2273 deletions
+25
View File
@@ -0,0 +1,25 @@
import type { DB } from '@/server/db'
/**
* 基础 Context - 所有请求都包含的上下文
*/
export interface BaseContext {
headers: Headers
}
/**
* 数据库 Context - 通过 db middleware 扩展
*/
export interface DBContext extends BaseContext {
db: DB
}
/**
* 认证 Context - 通过 auth middleware 扩展(未来使用)
*
* @example
* export interface AuthContext extends DBContext {
* userId: string
* user: User
* }
*/