bootsaas logo

AppPagination

Offers a simple API for dealing with pagination.

This is it's interface

interface AppPaginationProps { onNextPage: () => void; onPreviousPage: () => void; hasNext: boolean; hasPrevious: boolean; }

Example usage:

<AppPagination hasNext={page + 1 < data.totalPages} hasPrevious={page > 0} onNextPage={() => updatePage(page + 1)} onPreviousPage={() => updatePage(page - 1)} />
bootsaas logoCopyright © 2024 - All rights reserved