Skip to content

Commit

Permalink
debug
Browse files Browse the repository at this point in the history
  • Loading branch information
tombrunet committed May 13, 2024
1 parent c7a17d8 commit fa4e49d
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,10 @@ export class BrowserWrapper {
"desktop": 1200
}
const tab = await (await this.browser!).newPage()!;
tab.on('console', async e => {
const args = await Promise.all(e.args().map(a => a.jsonValue()));
console.log(...args);
});

// https://github.com/puppeteer/puppeteer/issues/8166
await tab.setUserAgent('Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.88 Safari/537.36')
Expand Down

0 comments on commit fa4e49d

Please sign in to comment.