mirror of
https://github.com/ful1e5/apple_cursor.git
synced 2025-05-14 23:24:48 -04:00
😎 index file
This commit is contained in:
parent
3d6b199669
commit
3b12514424
2 changed files with 13 additions and 1 deletions
13
src/index.ts
Normal file
13
src/index.ts
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
import puppeteer from "puppeteer";
|
||||||
|
|
||||||
|
(async () => {
|
||||||
|
const browser = await puppeteer.launch({
|
||||||
|
ignoreDefaultArgs: process.env.IS_LOCAL ? [" --single-process "] : [],
|
||||||
|
headless: true,
|
||||||
|
});
|
||||||
|
const page = await browser.newPage();
|
||||||
|
await page.goto("https://google.com");
|
||||||
|
await page.pdf({ path: "google.pdf" });
|
||||||
|
|
||||||
|
await browser.close();
|
||||||
|
})();
|
|
@ -1 +0,0 @@
|
||||||
console.log("Hello World");
|
|
Loading…
Add table
Add a link
Reference in a new issue