Gg
Explore posts from serversPPrisma
•Created by Gg on 8/31/2024 in #help-and-questions
Prisma Client: Injectable Setup Outside NestJS (with/without DI)?
In NestJS, the Prisma Client can be made injectable by extending
PrismaClient
and implementing lifecycle hooks like onModuleInit
to manage connections. Here's how it's typically done in NestJS:
1. How would a similar Prisma Client setup be implemented in a non-NestJS application (for example, an Express app) without using a dependency injection tool?
2. How would this setup change if you were to use a dependency injection tool (like Tsyringe or any other DI library) in your non-NestJS application?2 replies
Sharing the app type from my hono api to my client in a monorepo
I'm trying to share types between my Hono API and Svelte app. Currently doing this:
Importing directly from another app like this feels off. What's a better way to share types in a Turborepo setup? Thanks!
14 replies
background jobs with Hono + Bun
Hi all, I'm planning on building a backend with Hono and I'm looking for a solution to do background jobs (backed by a queue). Are there any recommendations in the bun ecosystem for doing this? So far, I've mostly seen BullMQ in the node ecosystem, but bun is not officially supported as far as I know. Is there an alternative for bun?
5 replies