Set custom cookie response #105
Answered
by
enisdenjo
xavierbeillas
asked this question in
Q&A
-
|
I want to set a new cookie in a resolver response. I was expecting to pass down server response from a custom context but only getting Thanks. |
Beta Was this translation helpful? Give feedback.
Answered by
enisdenjo
Aug 2, 2023
Replies: 1 comment 1 reply
-
|
But, I guess you're using one of the
|
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
xavierbeillas
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
graphql-httpcore handler is pure, it takes a request and returns a response. This response can be manipulated to your desires.But, I guess you're using one of the
use/handlers. So, here's a few examples:use/httpthe ServerResponse is available in the request context (req.context.res)use/http2use/expressuse/fastify, but as aFastifyReplyuse/koause/deno, the handler is also pure, so you'd just add headers to the returned response.use/bunuse/@netlify/functions