So I created a turborepo with Prisma following the tutorial I created a PrismaClient exported it , made suggested chages in turbo.json , the project builds correctly but when i start dev (pnpm run dev)
I get Warning: Failed to load the ES module: packages/prisma/src/index.ts
Which basically transaltes too ws-server and http-server are compiled with TypeScript → CommonJS Their output (dist/index.js) uses require() They import @repo/db @repo/db resolves to packages/prisma/src/index.ts That file is raw TypeScript with ES export Node tries to require() it → boom
How to build this prisma package and how to consume it correctly