YouTube Search
Search Pagination
Fetch additional search pages through the nextPage function returned by searchYouTube.
js
let page = await searchYouTube("node.js", { limit: 20 });
while (page) {
for (const video of page.videos) {
console.log(video.title);
}
page = await page.nextPage();
}End of pagination
The nextPage() method resolves to another SearchResult or null when no continuation is available.