-
-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Preload queries #6
Comments
Is preloading a query the same as instantiating the query before user navigation? The key difference should be allowing preloading in user actions (e.g., click, hover, etc.) and in lifecycle hooks. Should we introduce another API, like |
it is about instantiating the query. It doesn't have to be about navigation but it should integrate easily into that too. I'm not sure if a new API is needed yet. The idea is to have:
So maybe this is just a matter of documentation at this point. Not sure yet |
Currently doable with const queryCache = useQueryCache()
queryCache.setQueryData(['the key'], await fetchData()) Depending on the |
Allowing a query to be preloaded
Requires all the options rather than just the key as otherwise it might not exist
The text was updated successfully, but these errors were encountered: