Skip to main content

Class: ChannelPlaylists

Continuable of playlists inside a BaseChannel

Example

const channel = await youtube.findOne(CHANNEL_NAME, {type: "channel"});
await channel.playlists.next();
console.log(channel.playlists.items) // first 30 playlists

let newPlaylists = await channel.playlists.next();
console.log(newPlaylists) // 30 loaded playlists
console.log(channel.playlists.items) // first 60 playlists

await channel.playlists.next(0); // load the rest of the playlists in the channel

Hierarchy​

Properties​

channel​

• Optional channel: BaseChannel

The channel this playlists belongs to


client​

• client: Client

An instance of Client

Inherited from​

Continuable.client


continuation​

• Optional continuation: null | string

Inherited from​

Continuable.continuation


items​

• items: PlaylistCompact[] = []

Inherited from​

Continuable.items

Methods​

next​

▸ next(count?): Promise<PlaylistCompact[]>

Fetch next items using continuation token

Parameters​

NameTypeDefault value
countnumber1

Returns​

Promise<PlaylistCompact[]>

Inherited from​

Continuable.next