Nicolas
Creating inner context for AWS Lambda Context Options
It seems that I somehow need to tell all my exising code that a user will exist if called from the API, but not for internal calls, I am confused on how this is solved with the example online: https://trpc.io/docs/server/context#inner-and-outer-context
All they do is:
And I did something similar, but since we are defining
export type Context = inferAsyncReturnType<typeof createContextInner>;
, I don't see how it ever knows about the req
and res
, and thus there are errors everywhere5 replies