N
Neon6mo ago
optimistic-gold

Best way to develop Neon + Vercel Edge Middleware

I need to check the database to recalculate the state of the user and route them appropriately. I though of doing this in middleware, only to realize there's a whole other environment that middleware runs on. I saw that @neondatabase/serverless could support my usecase, but for local (no internet) development I didn't find a good solution.
2 Replies
optimistic-gold
optimistic-goldOP6mo ago
GitHub
GitHub - TimoWilhelm/local-neon-http-proxy: Connect to a local Post...
Connect to a local PostgreSQL database using the neon http proxy - TimoWilhelm/local-neon-http-proxy
ambitious-aqua
ambitious-aqua6mo ago
https://github.com/neondatabase/examples/tree/main/with-nextjs-drizzle-local-vercel here's an example of how you can with Next.js use the Neon's serverless driver for local and production use cases.

Did you find this page helpful?