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

Method getCurrentResult

packages/query-core/src/queryObserver.ts:321–323  ·  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). * * @example * ```ts * const result = observer.g

()

Source from the content-addressed store, hash-verified

319 * ```
320 */
321 getCurrentResult(): QueryObserverResult<TData, TError> {
322 return this.#currentResult
323 }
324
325 /**
326 * 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