-
The context is, I want to show a loading indicator when someone changes an input and thus invalidates the query key. I do NOT want to show this loading indicator when the data is just stale per the stale time - effectively distinguishing between deliberate updates and background updates. How can I do this? It's not obvious to me from the docs how I can make this distinction. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
you're conflating terms here. I'd need to see some code to understand what you are trying to achieve ... |
Beta Was this translation helpful? Give feedback.
You haven't mentioned that you are using
keepPreviousData
, so ...isPreviousData
is likely what you are looking for. This flag is set to true while you are seeing data from a previous query key.