TanStack Query
cancelQueries
Cancels matching queries; cooperating query functions consume the supplied signal.
Formal Syntax & Structure
react syntaxreact
client.cancelQueries({queryKey,exact:true})Working Example
Example Snippetreact
await client.cancelQueries({queryKey:["stock"],exact:true});