PrismaP
Prisma9mo ago
3 replies
Reis

Dynamic require of "node:fs" is not supported

After upgrading prisma to the latest version and exporting the client into a custom folder, when I build the application with esbuild I do have this node:fs problem.

schema.prisma:
generator client {
  provider     = "prisma-client-js"
  output       = "../generated"
  moduleFormat = "esm"
}

datasource db {
  provider  = "postgresql"
  url       = env("DATABASE_URL")
  directUrl = env("DATABASE_DIRECT_URL")
}
Was this page helpful?