feat(id): brand WorkspaceID through Drizzle and Zod schemas (#16964)
This commit is contained in:
@@ -1,9 +1,10 @@
|
||||
import { sqliteTable, text } from "drizzle-orm/sqlite-core"
|
||||
import { ProjectTable } from "../project/project.sql"
|
||||
import type { ProjectID } from "../project/schema"
|
||||
import type { WorkspaceID } from "./schema"
|
||||
|
||||
export const WorkspaceTable = sqliteTable("workspace", {
|
||||
id: text().primaryKey(),
|
||||
id: text().$type<WorkspaceID>().primaryKey(),
|
||||
type: text().notNull(),
|
||||
branch: text(),
|
||||
name: text(),
|
||||
|
||||
Reference in New Issue
Block a user