T
TanStack11mo ago
xenial-black

Reset query state when using skipToken

I'm using skipToken, but whenever it is active all previous query data stays in the query. Is there a way to just make the data be undefined in this case?
2 Replies
xenial-black
xenial-blackOP11mo ago
I know I could just return undefined in my queryFn instead of using skipToken but I really want to reset the entire query state. This would save me a bunch of manual checks
ambitious-aqua
ambitious-aqua11mo ago
Can you show some code? I don't understand the scenario

Did you find this page helpful?