9 lines
331 B
TypeScript
9 lines
331 B
TypeScript
|
|
import { pgTable, text, timestamp } from "drizzle-orm/pg-core";
|
||
|
|
|
||
|
|
export const users = pgTable("users", {
|
||
|
|
id: text("id").primaryKey().$defaultFn(() => crypto.randomUUID()),
|
||
|
|
email: text("email").notNull().unique(),
|
||
|
|
passwordHash: text("password_hash").notNull(),
|
||
|
|
createdAt: timestamp("created_at").defaultNow().notNull(),
|
||
|
|
});
|