Skip to main content

Class: ChannelShorts

Continuable of shorts inside a BaseChannel

Example

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

let newShorts = await channel.short.next();
console.log(newShorts) // 30 loaded shorts
console.log(channel.short.items) // first 60 shorts

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

Hierarchy

Properties

channel

Optional channel: BaseChannel

The channel this shorts belongs to


client

client: Client

An instance of Client

Inherited from

Continuable.client


continuation

Optional continuation: null | string

Inherited from

Continuable.continuation


items

items: VideoCompact[] = []

Inherited from

Continuable.items

Methods

next

next(count?): Promise<VideoCompact[]>

Fetch next items using continuation token

Parameters

NameTypeDefault value
countnumber1

Returns

Promise<VideoCompact[]>

Inherited from

Continuable.next