Skip to content

Latest commit

 

History

History
191 lines (85 loc) · 1.98 KB

youtubes.js.pagination.md

File metadata and controls

191 lines (85 loc) · 1.98 KB

Home > youtubes.js > Pagination

Pagination class

Provides utility methods for pagination.

Signature:

export declare class Pagination<T> 

Constructors

Constructor

Modifiers

Description

(constructor)({ data, logger, prevToken, nextToken, resultsPerPage, totalResults, getWithToken, })

Constructs a new instance of the Pagination class

Properties

Property

Modifiers

Type

Description

data

T

The data of the current page.

resultsPerPage

number

The number of results included in the API response.

totalResults

number

The total number of results in the result set.

Methods

Method

Modifiers

Description

all()

Fetches all pages data.

next()

Fetches the next page.

prev()

Fetches the previous page.