rtzrtz.
Explore posts from serversbehaviour of createAsync in hooks - why cached?
I'm trying to get a better understanding on createAsync & query, and weather or not it is an appropriate way to share state.
I created a hook and use it like this.
This works perfectly fine. But I'm confused why the logs appear in the console, but no requests are made. I understood, that the query() cashes for only 5 seconds - so why is it not making requests all the timem even on navigation? I can import the hook and access the data from everywhere simultaneously.
Honestly this is the behaviour i hoped for (its easy to revalidate the cash), but I'd like to fully understand why this works.
Thanks!
❤️
14 replies
DTDrizzle Team
•Created by rtzrtz. on 11/27/2023 in #help
import of drizzle-orm makes typescript complain about missing "document"

5 replies