import { scrollToLoadContent } from "@intuned/browser";
import { BrowserContext, Page } from "playwright";
interface Params {}
export default async function handler(
params: Params,
page: Page,
context: BrowserContext
) {
// Scroll through entire page content
await page.goto("https://sandbox.intuned.dev/infinite-scroll");
await scrollToLoadContent({
source: page,
});
// Will keep scrolling until the page has loaded all content or the maxScrolls is reached.
}