patchamamma
Nuxt Plugin using `useCookie` composable error.
Well of course I can fix this with just returning the authToken when calling the
refreshTokenAction
function. But I am just curious how the flow is working now in Nuxt, this is an aspect I'm having difficulty wrapping my head around.7 replies
Nuxt Plugin using `useCookie` composable error.
Thanks a lot, I did manage to fix the composable problem (example below). Now I need to find out why the authToken.value is empty after a refreshCookie() 😂 probably again a SSR or browser thing, since the refreshToken is for the browser.
7 replies
Nuxt Plugin using `useCookie` composable error.
Some context: I am using a jwt auth endpoint on a custom nodeJS server, so I am not using the nuxt auth package or SSR functionality (server folder).
When setting the
ssr
to false in the nuxt.config.ts
this works perfectly fine. But of course I don't want to lose out on SSR in some pages/components.7 replies