We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5c1e843 commit 0f15863Copy full SHA for 0f15863
1 file changed
pdf-export.mjs
@@ -4,9 +4,15 @@ import * as path from "path";
4
const browser = await puppeteer.launch();
5
const page = await browser.newPage();
6
7
-await page.goto(
8
- path.join(path.dirname(import.meta.url), "index.html?print-pdf")
+const slidesPath = path.join(
+ path.dirname(import.meta.url),
9
+ "index.html?print-pdf"
10
);
11
+console.log(`Navigating to ${slidesPath}`);
12
+
13
+await page.goto(slidesPath);
14
15
+console.log(`Generating PDF version of the slides for ${await page.title()}`);
16
17
await page.pdf({ path: "slides.pdf", format: "A4", timeout: 0 });
18
0 commit comments