Goal
All the Titanic passengers are in this page.
Create an agent to scrape every passenger.
Documentation
Instructions
-
Create the script
scraping-challenge-1
-
Access this page using
Puppeteer.launch(), Puppeteer.newPage() and Puppeteer.Page.goto()
to open the page.
-
Wait for an element to load before scraping with
Puppeteer.Page.waitForSelector()
.
-
Use the function
Puppeteer.Page.addScriptTag()
to inject jQuery in the page.
-
Create a function to scrape the page with jQuery now that it is injected and execute it in the page using
Puppeteer.Page.evaluate()
.
-
Send the data using
buster.setResultObject()
.
Solution