10 lines
258 B
TypeScript
10 lines
258 B
TypeScript
import { PrismaClient } from "@prisma/client";
|
|
|
|
import { singleton } from "./singleton.server";
|
|
|
|
// Hard-code a unique key, so we can look up the client when this module gets re-imported
|
|
export const db = singleton(
|
|
"prisma",
|
|
() => new PrismaClient()
|
|
);
|