Skip to content

Instantly share code, notes, and snippets.

@converge
Last active October 25, 2018 17:37
Show Gist options
  • Save converge/eb02ca717ddfc565f40c78d447a99478 to your computer and use it in GitHub Desktop.
Save converge/eb02ca717ddfc565f40c78d447a99478 to your computer and use it in GitHub Desktop.
module.exports = {
page: null,
start: async function() {
const puppeteer = require('puppeteer');
const browser = await puppeteer.launch( {headless: false} );
const this.page = await browser.newPage();
await this.page.goto('https://www.google.com');
},
stop: async function() {
// const this.page = browser.newPage()
await this.page.close()
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment