| 1 | import { users } from "@/worker/db/d1/schema"; |
| 2 | import type { Db } from "@/worker/db/d1/client"; |
| 3 | |
| 4 | type AppVariables = { |
| 5 | db: Db; |
| 6 | user: typeof users.$inferSelect | null; |
| 7 | jwtPayload: { sub: string; jti: string } | null; |
| 8 | }; |
| 9 | |
| 10 | export type AppContext = { Bindings: Env; Variables: AppVariables }; |