Skip to content

PaginateSelector

Pages through a list by page number, reporting totals with each page.

TResult

The type of each result.

execute(): Promise<PageSelectorResult<TResult>>

Runs the selection and returns the requested page with its totals.

Promise<PageSelectorResult<TResult>>


first(): Promise<TResult | undefined>

Runs the selection for a single result.

Promise<TResult | undefined>

The first result, or undefined when nothing matches.


limit(value): this

Sets the page size.

number

A positive integer.

this

(error-008-invalid-selector-limit) when value is not a positive integer.