#one query depending on another

5 messages · Page 1 of 1 (latest)

rain lotus
#

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?

plucky olive
reef kindle
#

enabled is used exactly for this usecase.

enabled: !!formOptionsId

rain lotus
#

They don't share variables

#

I wanted to ask if there's a configuration like flag to make one query dependant on another