Cookies not updating on h3 server in Nuxt 3
Could you please help me understand why cookies aren't being updated on the h3 server?
I created an endpoint:
I retrieve the cookie and log it to the console, everything seems fine:
Then, I delete it:
But when I try to retrieve it again, it still returns and logs the old version
:
Then, I try to replace its value:
But when I try to retrieve it again, it still returns and logs the old version
:
I tried adding a delay and using await (even though these functions are not async according to h3 cookie examples), but nothing seems to help.
What could be the issue?
I created an endpoint:
server/api/auth/refresh.tsI retrieve the cookie and log it to the console, everything seems fine:
Then, I delete it:
But when I try to retrieve it again, it still returns and logs the old version
Then, I try to replace its value:
But when I try to retrieve it again, it still returns and logs the old version
I tried adding a delay and using await (even though these functions are not async according to h3 cookie examples), but nothing seems to help.
What could be the issue?