Skip to content

Instantly share code, notes, and snippets.

@manoj9788
Created May 8, 2020 20:00
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 manoj9788/3188aa5e599bb73edec4aa7cccbc82e6 to your computer and use it in GitHub Desktop.
Save manoj9788/3188aa5e599bb73edec4aa7cccbc82e6 to your computer and use it in GitHub Desktop.
const { chromium } = require('playwright');
(async () => {
const browser = await chromium.launch();
const context = await browser.newContext();
const page = await context.newPage();
page.on('pageerror', console.log);
await page.goto('https://www.gov.uk/');
const snapshot = await page.accessibility.snapshot();
console.log(snapshot);
await browser.close();
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment