Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //..
- chromium.launch({ headless: true }).then(async browser => {
- const page = await browser.newPage()
- // Navigate to target URL
- await page.goto('http://httpbin.io/ip');
- // Get page HTML
- const textContent = await page.evaluate(() => document.body.textContent);
- console.log(textContent);
- await browser.close()
- })
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement