Created
January 9, 2020 21:30
-
-
Save nicktaylor/1be8af3dfa41e58c4aabd95152058420 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import "babel-polyfill" | |
const puppeteer = require('puppeteer'); | |
const url = 'https://www.racingpost.com'; | |
puppeteer | |
.launch() | |
.then(browser => browser.newPage()) | |
.then(page => page.goto(url).then(() => page.content())) | |
.then(html=> console.log(html)) | |
.catch(err => console.log(err)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment