-
Notifications
You must be signed in to change notification settings - Fork 1
feat: add database-neon module #8
Copy link
Copy link
Open
Labels
good first issueGood for newcomersGood for newcomersmodule: databaseRelated to database systems, ORM integrations, or data modeling.Related to database systems, ORM integrations, or data modeling.new-modulebuild something herebuild something here
Metadata
Metadata
Assignees
Labels
good first issueGood for newcomersGood for newcomersmodule: databaseRelated to database systems, ORM integrations, or data modeling.Related to database systems, ORM integrations, or data modeling.new-modulebuild something herebuild something here
Summary
Add Neon (serverless Postgres) as a database option, alongside the existing
database-postgresqlmodule.Why
Neon is the dominant serverless Postgres provider — used heavily with Next.js and Vercel deployments.
It has a distinct client (
@neondatabase/serverless) optimised for connection pooling in serverless environments where long-livedpgpools aren't viable.Files to generate
src/db/client.ts— Neon serverless client with pool setupsrc/db/migrations/001_init.sql.env.example— withDATABASE_URL(Neon connection string format)Implementation hints
Add
packages/modules/src/database/neon.ts→ use
supabase.tsorpostgresql.tsas the templateKey dependency:
@neondatabase/serverlessThe
client.tsshould:neon()for single queriesPoolfor transactionsRegister in same places as other database modules
Contributor guidance
Refer to CONTRIBUTING.md → "Adding a New Module"
Acceptance criteria
foundation createlists Neon as a database optionclient.tstype-checks cleanly.env.examplecontainsDATABASE_URL=postgresql://...