Skip to content
Source
Sign inSign up
TanStack/query
Open History to see the last commit

QueryFunction.md

36 lines647 Bytes

Type Alias: QueryFunction()<T, TQueryKey, TPageParam>

type QueryFunction<T, TQueryKey, TPageParam> = (context) => T | Promise<T>;

Defined in: packages/query-core/src/types.ts:96

Type Parameters

T

T = unknown

TQueryKey

TQueryKey extends QueryKey = QueryKey

TPageParam

TPageParam = never

Parameters

context

QueryFunctionContext<TQueryKey, TPageParam>

Returns

T | Promise<T>