one query depending on another
Hi, i have a situation where my
useItem query depends on my useFormOptions query, and sometimes useItem finishes fetching before useFormOptions.
What would be the correct way to always prefetch form options (or fetch if stale) before actually fetching item?4 Replies
deep-jade•3y ago
use the enabled flag on useItem?
unwilling-turquoise•3y ago
enabled is used exactly for this usecase.
like-goldOP•3y ago
They don't share variables
I wanted to ask if there's a configuration like flag to make one query dependant on another
optimistic-gold•3y ago
Yes, it's
enabled 😅