Is there a way to set cookies on page load?
Do I need to call and endpoint just to do that, or is there something I can do with
routeData
/createServerData
? Even better, is there a middleware-like thing that can access the response? Would like to store functions inside request.locals
(if that even exists).3 Replies
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Yes, just waiting for this PR to get merged
https://github.com/solidjs/solid-start/pull/485
GitHub
Expose responseHeaders to createServerData$ by oscartbeaumont · Pul...
This PR exposes a way to set HTTP headers on the response within the createServerData$ function.
This makes it possible to do:
export function routeData() {
return createServerData$((_, { respons...
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View