Hello, i'm using Puppeteer actor. I want to open new page inside the pageFunction.

so i have the initial page. but since i still need the data there i need to create new page to visit a link. i don't know how i can do that if anyone can help me. thanks
5 Replies
exotic-emerald
exotic-emerald3y ago
page.goto([URL])
graceful-blue
graceful-blueOP3y ago
nop, i need to declare a new variable(e.g page2). i don't want to use the "page" because it has data that i don't want it to change when i go to the new one url
exotic-emerald
exotic-emerald3y ago
add new request with userData and add whatever values you need from page1 to it, thats expected way to manage data details until you get what you want to save in dataset
graceful-blue
graceful-blueOP3y ago
Okay, thanks.
adverse-sapphire
adverse-sapphire2y ago
or simply await page.browser.newPage()

Did you find this page helpful?