CursorPage
CursorPage<
T> =object
Defined in: packages/db/src/types.ts:282
A page of results from cursor-based pagination.
Use nextCursor to fetch the next page. When nextCursor is null, there are no more pages.
Example
Section titled “Example”const page: CursorPage<Post> = await db.query(posts) .paginate({ type: "cursor", cursor: null, limit: 20 }) .run({});
if (page.nextCursor) { // Fetch next page with page.nextCursor}Type Parameters
Section titled “Type Parameters”T
The row type.
Properties
Section titled “Properties”items:
T[]
Defined in: packages/db/src/types.ts:284
The items on this page.
nextCursor
Section titled “nextCursor”nextCursor:
string|null
Defined in: packages/db/src/types.ts:286
Opaque cursor for the next page, or null if this is the last page.