@playlive/react-query
    Preparing search index...

    Interface UseInfiniteDonationsResult<TPage>

    Tier-specific return shape for useInfiniteDonations.

    The data payload is TanStack's standard { pages, pageParams } shape; the rest match the standard UseFetchResult fields plus the pagination knobs (fetchNextPage, hasNextPage, isFetchingNextPage).

    interface UseInfiniteDonationsResult<TPage> {
        data:
            | {
                pageParams: (string | number | null | undefined)[];
                pages: TPage[];
            }
            | undefined;
        error: Error
        | null;
        fetchNextPage: () => Promise<void>;
        fetchPreviousPage: () => Promise<void>;
        hasNextPage: boolean;
        hasPreviousPage: boolean;
        isFetching: boolean;
        isFetchingNextPage: boolean;
        isFetchingPreviousPage: boolean;
        isLoading: boolean;
        isPending: boolean;
        refetch: (options?: HookRefetchOptions) => Promise<void>;
    }

    Type Parameters

    • TPage

      Per-page payload shape (e.g. PaginatedResponse<TiltifyDonation, TiltifyPaginationMetadata>).

    Index
    data:
        | { pageParams: (string | number | null | undefined)[]; pages: TPage[] }
        | undefined

    TanStack-shape paginated data envelope.

    error: Error | null

    Most recent error thrown by the fetcher, or null.

    fetchNextPage: () => Promise<void>

    Triggers fetching the next page; awaits the result.

    fetchPreviousPage: () => Promise<void>

    Triggers fetching the previous page (Tiltify only — the Twitch charity donations endpoint doesn't expose a reverse cursor). No-op when hasPreviousPage is false.

    hasNextPage: boolean

    false once the cursor returns no further page.

    hasPreviousPage: boolean

    false once the reverse-cursor returns no further page. Twitch charity donations never expose a before cursor, so this is permanently false on the Twitch path.

    isFetching: boolean

    true whenever any fetch is in flight (initial / refetch / next-page / prev-page).

    isFetchingNextPage: boolean

    true while a next-page fetch is in flight specifically.

    isFetchingPreviousPage: boolean

    true while a previous-page fetch is in flight specifically.

    isLoading: boolean

    true from mount until first resolve / reject.

    isPending: boolean

    true while the query has neither resolved data nor a captured error — i.e. we haven't checked/fetched yet. Passed through directly from TanStack Query v5's isPending.

    refetch: (options?: HookRefetchOptions) => Promise<void>

    Manually refetch every page from the beginning. Defaults to cancelling any in-flight request first (cancelRefetch: true); pass { cancelRefetch: false } to preserve an in-flight fetch (useful for polling loops that don't want to interrupt a cursor walk).