Extend context to use db query with "c.db"? #3643
Unanswered
patelharsh9797
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Is there anywat to extend exsisiting context and add new key "db" which we can use to get all the database query from drizzle?
something which trpc do with createTRPCContext.
Here is example i used to do in trpc:
export const createTRPCContext = async (opts: { headers: Headers }) => { return { db, ...opts, }; };
Beta Was this translation helpful? Give feedback.
All reactions