Skip to main content

Interface: PreparedQuery<GeneratedSchema, TFunction>#

Type parameters#

NameType
GeneratedSchemaobject
GeneratedSchema.queryobject
TFunction(query: GeneratedSchema[query], args: any) => any

Properties#

callback#

callback: TFunction

Defined in: react/src/query/preparedQuery.ts:40

Methods#

preload#

preload(...__namedParameters: undefined extends Parameters<TFunction>[1] ? [Parameters<TFunction>["1"]?] : [Parameters<TFunction>[1]]): Promise<ReturnType<TFunction>>

Parameters:#

NameType
...__namedParametersundefined extends Parameters<TFunction>[1] ? [Parameters<TFunction>["1"]?] : [Parameters<TFunction>[1]]

Returns: Promise<ReturnType<TFunction>>

Defined in: react/src/query/preparedQuery.ts:21


refetch#

refetch(...__namedParameters: undefined extends Parameters<TFunction>[1] ? [Parameters<TFunction>["1"]?] : [Parameters<TFunction>[1]]): Promise<ReturnType<TFunction>>

Parameters:#

NameType
...__namedParametersundefined extends Parameters<TFunction>[1] ? [Parameters<TFunction>["1"]?] : [Parameters<TFunction>[1]]

Returns: Promise<ReturnType<TFunction>>

Defined in: react/src/query/preparedQuery.ts:26


usePrepared#

usePrepared(opts?: UsePreparedQueryOptions): object

Parameters:#

NameType
opts?UsePreparedQueryOptions

Returns: object

NameType
calledboolean
dataundefined | ReturnType<TFunction>
error?GQlessError
isLoadingboolean
isRefetchingboolean

Defined in: react/src/query/preparedQuery.ts:31

Last updated on by Sam Denty