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

Method getCurrentResult

packages/query-core/src/queryObserver.ts:330–332  ·  view source on GitHub ↗

* Returns the most recently computed `QueryObserverResult` for the * observed query. This is a point-in-time read; to be notified of updates * as they happen, subscribe to the observer instead (its inherited * `subscribe` method). * @returns The observer's latest result. * @example

()

Source from the content-addressed store, hash-verified

328 * ```
329 */
330 getCurrentResult(): QueryObserverResult<TData, TError> {
331 return this.#currentResult
332 }
333
334 /**
335 * Wraps a `QueryObserverResult` in a `Proxy` that records which properties are read, via

Callers 15

getOptimisticResultMethod · 0.95
onConnectedMethod · 0.45
onQueryClientChangedMethod · 0.45
readCurrentMethod · 0.45
refreshOptionsMethod · 0.45
syncClientMethod · 0.45
refreshOptionsMethod · 0.45
onConnectedMethod · 0.45
onQueryClientChangedMethod · 0.45
readCurrentMethod · 0.45
refreshOptionsMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected