Circle V2 API Docs
    Preparing search index...

    Type Alias InfiniteLoaderProps<T>

    type InfiniteLoaderProps<T> = {
        children: (items: T[]) => ReactNode;
        emptyFallback?: ReactNode;
        fetchNextPage: () => void;
        hasMore: boolean;
        isFetchingNextPage: boolean;
        isLoading: boolean;
        items: T[];
        loadingFallback?: ReactNode;
        scrollContainerRef?: RefObject<HTMLElement | null>;
    }

    Type Parameters

    • T
    Index

    Properties

    children: (items: T[]) => ReactNode

    Render function that receives the items array.

    emptyFallback?: ReactNode

    Shown when loading is complete but there are no items.

    fetchNextPage: () => void

    Callback to fetch the next page.

    hasMore: boolean

    Whether more pages exist beyond what has been fetched.

    isFetchingNextPage: boolean

    Whether a subsequent page is currently being fetched.

    isLoading: boolean

    Whether the initial page is still loading.

    items: T[]

    Flattened items array (typically from useInfiniteItems).

    loadingFallback?: ReactNode

    Shown while the initial page is loading.

    scrollContainerRef?: RefObject<HTMLElement | null>

    When provided, scopes the IntersectionObserver to this scroll container instead of the viewport.