MCPcopy Create free account
hub / github.com/TanStack/query / onOnline

Method onOnline

packages/query-core/src/query.ts:501–508  ·  view source on GitHub ↗

@internal

()

Source from the content-addressed store, hash-verified

499
500 /** @internal */
501 onOnline(): void {
502 const observer = this.observers.find((x) => x.shouldFetchOnReconnect())
503
504 observer?.refetch({ cancelRefetch: false })
505
506 // Continue fetch if currently paused
507 this.#retryer?.continue()
508 }
509
510 /** @internal */
511 addObserver(observer: QueryObserver<any, any, any, any, any>): void {

Callers 5

useQuery.test.tsxFile · 0.45
useQuery.test.tsxFile · 0.45
useQuery.test.tsxFile · 0.45
mountMethod · 0.45
query.test.tsxFile · 0.45

Calls 4

refetchMethod · 0.80
continueMethod · 0.80
findMethod · 0.45

Tested by

no test coverage detected