Tom
Preventing Refetching in Component
https://nuxt.com/docs/getting-started/data-fetching#caching-and-refetching
useFetch and useAsyncData use keys to prevent refetching the same data.
This was the part that lead be to believe it worked that way.6 replies
A/B Testing Middleware
Pretty simple in the end and is much less code that Next. It actually makes plenty of sense but I had it in my head that useCookie was not accessible inside
defineNuxtRouteMiddleware
, I limited myself from the very beginning 😅 turns out I was just missing the .global
6 replies
A/B Testing Middleware
It seems there is
/middleware
and /server/middleware
I'm not entirely sure of the difference but I've come up:
Then:
Which works, okay, but on the initial load when it sets the cookie I'm getting a Hydration text content mismatch
refreshing after that works as expected.6 replies