import { BasedQuery } from '@based/client';
export type SortOptions = {
    $field: string;
    $order: 'asc' | 'desc';
};
type CurrentRef = {
    offset: number;
    blocks: number;
    scrollY: number;
    items: any[];
    timer: ReturnType<typeof setTimeout>;
    subs: {
        [subId: string]: () => void;
    };
};
export declare const useInfiniteQuery: ({ query, getQueryItems, rowHeight, itemCount, height, limit, treshold, queryId, delay, sortOptions, }: {
    query?: (start: number, limit: number, sortOptions: SortOptions) => BasedQuery;
    getQueryItems?: (data: any) => any[];
    rowHeight: number;
    itemCount: number;
    height: number;
    limit?: number;
    delay?: number;
    treshold?: number;
    queryId?: string;
    sortOptions?: SortOptions;
}) => {
    loading: boolean;
    itemCount: number;
    items: any[];
    cache: CurrentRef;
    onScrollY: (scrollY: number) => void;
};
export {};
