Data Layer Handbook

0•

Guides architectural decisions between Prisma, Drizzle, and raw SQL in Next.js applications.

The Data Layer Handbook provides structured decision matrices and best practices to help developers choose the optimal data access layer for Next.js applications. It evaluates the trade-offs between Prisma, Drizzle ORM, and raw SQL or Kysely based on project constraints such as edge runtime support, connection pooling, team familiarity, and reporting needs. With specialized guidance on serverless connection management (PgBouncer, Supavisor, Neon), edge driver limitations, and query security, this skill ensures robust, scalable database architecture while preventing common pitfalls like connection exhaustion and type drift.

主要功能

01Decision matrix comparing Prisma, Drizzle, and raw SQL for greenfield and legacy projects
02Serverless connection pooling patterns to prevent unbounded client instantiations
03Edge runtime compatibility guidance for Prisma Data Proxy and Drizzle edge drivers
04Read-only query safety checks to detect and flag string-concatenated SQL injection risks
05Integration guidance with database-schema-agent for deep Prisma schema modeling
060 GitHub stars

使用场景

01Selecting the right ORM or query builder when bootstrapping a new Next.js project
02Configuring database connection pooling and drivers for serverless and edge deployments
03Troubleshooting database connection limits, runtime mismatches, and schema type drift