Inconsistent behavior of skip
option in useQuery
leading to stale results
#11631
Labels
skip
option in useQuery
leading to stale results
#11631
Issue Description
Consider the following component:
If the variables change while the query is being skipped, I would expect that, when the component re-renders with
skip = false
, the query is made with up-to-date variables anddata
would then reflect the GraphQL query result with those variables applied. However, in some cases (see link to reproduction), the data remains stale and the query is never fetched.Link to Reproduction
https://codesandbox.io/p/sandbox/dazzling-violet-9p6hlz
Reproduction Steps
@apollo/client
version3.9.5
The text was updated successfully, but these errors were encountered: