mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
16 lines
411 B
JavaScript
16 lines
411 B
JavaScript
/**
|
|
* @license
|
|
* Copyright 2024 Google Inc.
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
*/
|
|
(async () => {
|
|
const [, , puppeteerRoot, options] = process.argv;
|
|
const browser = await require(puppeteerRoot).launch(JSON.parse(options));
|
|
const page = await browser.newPage();
|
|
await page.evaluate(() => {
|
|
return console.error('message from dumpio');
|
|
});
|
|
await page.close();
|
|
await browser.close();
|
|
})();
|