API Documentation / @pinia/colada / UseQueryEntryExtensions
Interface: UseQueryEntryExtensions<TData, TError, TDataInitial>
Allows defining extensions to the query entry that are returned by useQuery().
Type Parameters
TData
TData
TError
TError
TDataInitial
TDataInitial extends TData | undefined = undefined
Properties
dataUpdatedAt
dataUpdatedAt: ShallowRef<number>;Timestamp of when data was last successfully fetched. TanStack Query compatible property.
errorUpdatedAt
errorUpdatedAt: ShallowRef<number>;Timestamp of when an error last occurred. TanStack Query compatible property.
fetchStatus
fetchStatus: ComputedRef<FetchStatus>;TanStack Query compatible fetch status. Maps to: 'fetching' when loading, 'idle' otherwise. Note: 'paused' is not currently supported.
isDelaying
isDelaying: ShallowRef<boolean>;Returns whether the query is currently delaying its asyncStatus from becoming 'loading'. Requires the PiniaColadaDelay plugin.
isError
isError: ComputedRef<boolean>;Whether the query status is 'error'. TanStack Query compatible property.
isFetched
isFetched: ShallowRef<boolean>;Whether the query has fetched at least once. TanStack Query compatible property.
isFetchedAfterMount
isFetchedAfterMount: ShallowRef<boolean>;Whether the query has fetched after component mount. TanStack Query compatible property.
isFetching
isFetching: ComputedRef<boolean>;Whether the query is currently fetching (asyncStatus === 'loading'). TanStack Query compatible property.
isLoadingError
isLoadingError: ComputedRef<boolean>;Whether the query errored on initial load (never had data). TanStack Query compatible property.
isRefetchError
isRefetchError: ComputedRef<boolean>;Whether the query errored on refetch (had data before). TanStack Query compatible property.
isRefetching
isRefetching: ComputedRef<boolean>;Whether the query is refetching (fetching but not initial load). TanStack Query compatible property.
isRetrying
isRetrying: ShallowRef<boolean>;Whether the query is currently retrying. Requires the @pinia/colada-plugin-retry plugin.
isStale
isStale: ComputedRef<boolean>;Whether the query data is stale. TanStack Query compatible property.
isSuccess
isSuccess: ComputedRef<boolean>;Whether the query status is 'success'. TanStack Query compatible property.
retry?
optional retry: object;Plain object with retry state for devtools. Only present in development mode.
isRetrying
isRetrying: boolean;retryCount
retryCount: number;retryError
retryError: unknown;retryCount
retryCount: ShallowRef<number>;The number of retries that have been scheduled so far. Resets on success or manual refetch. Requires the @pinia/colada-plugin-retry plugin.
retryError
retryError: ShallowRef<TError | null>;The error that triggered the current retry. null when not retrying or when retries are exhausted. Requires the @pinia/colada-plugin-retry plugin.