Skip to content

Instantly share code, notes, and snippets.

@HugoJBello
Created November 13, 2018 16:25
Show Gist options
  • Save HugoJBello/6130f96d020b64f9cd60d923500c67d5 to your computer and use it in GitHub Desktop.
Save HugoJBello/6130f96d020b64f9cd60d923500c67d5 to your computer and use it in GitHub Desktop.
puppeteer-rasp-minimal-example.js
const puppeteer = require('puppeteer');
(async () => {
const browser = await puppeteer.launch({executablePath: '/usr/bin/chromium-browser'});
const page = await browser.newPage();
await page.goto('https://example.com');
await page.screenshot({path: 'example.png'});
await browser.close();
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment