Prisma ORM v5.11.0 introduces Preview support for edge functions, enabling direct database access from Vercel Edge Functions, Vercel Edge Middleware, Cloudflare Workers, and Cloudflare Pages without requiring Prisma Accelerate as a proxy. Three key obstacles were overcome: the new driver adapters feature allows using compatible Node.js database drivers, the query engine size was drastically reduced to fit edge runtime bundle limits, and Prisma Client was updated to work around limited Node.js API availability in V8 isolates. A step-by-step tutorial demonstrates setting up a Cloudflare Worker with a PlanetScale database using the PlanetScale serverless driver and its Prisma driver adapter.

6m read timeFrom prisma.io
Post cover image
Table of contents
What are edge functions?Database access in edge functions with Prisma ORM 🎉How to use Prisma ORM in an edge functionTry it out and share your feedback
1 Impression