Skip to content

Instantly share code, notes, and snippets.

@paulbjensen
Created June 18, 2018 05:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save paulbjensen/6e2ae767976eac4641be48fe28a03a79 to your computer and use it in GitHub Desktop.
Save paulbjensen/6e2ae767976eac4641be48fe28a03a79 to your computer and use it in GitHub Desktop.
An example of using Puppeteer, for an article on Medium
const puppeteer = require('puppeteer');
(async () => {
const browser = await puppeteer.launch();
const page = await browser.newPage();
await page.goto('https://google.co.uk');
await page.screenshot({path: 'google.co.uk.png'});
await browser.close();
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment