Next.js Discord

Discord Forum

how to share cookie between domain and subdomain

Answered
MyMy posted this in #help-forum
Open in Discord
As the title above, I want to share cookie between domain and subdomain. How can I do that, if it has example where can I find it?
Answered by fuma
you can achieve it with domain property, for example, if you have a domain "example.com","Set-Cookie: name=value; domain=example.com" works
Same for HTTP-only cookies
View full answer

2 Replies

you can achieve it with domain property, for example, if you have a domain "example.com","Set-Cookie: name=value; domain=example.com" works
Same for HTTP-only cookies
Answer
Thank I made it