Skip to content
Discussion options

You must be logged in to vote

you need to make skip part of the queryKey. the key is like a dependency array to the query. it's what makes the query decide when it needs to run a request - it's not just requesting on every re-render - only when the key changes (or when you mount a new subscriber, focus the window or reconnect)

actually, all variables should be part of the queryKey.

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@steven-js
Comment options

@TkDodo
Comment options

@steven-js
Comment options

Answer selected by steven-js
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants