* The inverse of QueryClient#mount — called by a framework adapter's * `QueryClientProvider`-equivalent when it unmounts. Only tears down the focus/online * listeners once the mount count returns to `0`.
()
| 124 | * listeners once the mount count returns to `0`. |
| 125 | */ |
| 126 | unmount(): void { |
| 127 | this.#mountCount-- |
| 128 | if (this.#mountCount !== 0) return |
| 129 | |
| 130 | this.#unsubscribeFocus?.() |
| 131 | this.#unsubscribeFocus = undefined |
| 132 | |
| 133 | this.#unsubscribeOnline?.() |
| 134 | this.#unsubscribeOnline = undefined |
| 135 | } |
| 136 | |
| 137 | /** |
| 138 | * Returns the number of queries in the cache that are currently fetching, optionally |
no outgoing calls