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

Function isGetter

packages/vue-query/src/usePrefetchQuery.ts:54–56  ·  view source on GitHub ↗

* Checks whether an option was passed as a getter function. * @param value - The option value. * @returns `true` if `value` is a function.

(value: MaybeRefOrGetter<T>)

Source from the content-addressed store, hash-verified

52 * @returns `true` if `value` is a function.
53 */
54function isGetter<T>(value: MaybeRefOrGetter<T>): value is () => T {
55 return typeof value === 'function'
56}
57
58/**
59 * `usePrefetchQuery` does not return anything — it fires a prefetch as a reactive side effect, useful for

Callers 1

usePrefetchQueryFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected