@farberg/reveal-template 1.0.66 → 1.0.67
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/scripts/generate_pdfs.js +3 -3
package/package.json
CHANGED
package/scripts/generate_pdfs.js
CHANGED
|
@@ -12,7 +12,7 @@ const cwd = process.cwd()
|
|
|
12
12
|
const slides_dir = cwd
|
|
13
13
|
const pdf_dir = path.join(cwd, '__pdfs__')
|
|
14
14
|
const host = os.hostname()
|
|
15
|
-
const port =
|
|
15
|
+
const port = 1252
|
|
16
16
|
const verbose = true
|
|
17
17
|
const package_json = JSON.parse(fs.readFileSync('package.json'))
|
|
18
18
|
const combined_pdf_name = combined_pdf(package_json)
|
|
@@ -112,11 +112,11 @@ async function convert_to_pdf_single(todo) {
|
|
|
112
112
|
const browser = await puppeteer.launch({ headless: 'new' })
|
|
113
113
|
const page = await browser.newPage();
|
|
114
114
|
|
|
115
|
-
await page.goto(todo.presentation_url, { timeout:
|
|
115
|
+
await page.goto(todo.presentation_url, { timeout: 10000, waitUntil: ['load', 'domcontentloaded'] });
|
|
116
116
|
|
|
117
117
|
const selector = 'div.lecturetitle > h1'
|
|
118
118
|
try {
|
|
119
|
-
await page.waitForSelector(selector, { timeout:
|
|
119
|
+
await page.waitForSelector(selector, { timeout: 10000 })
|
|
120
120
|
} catch (e) {
|
|
121
121
|
console.error(`Unable to find selector ${selector} on ${todo.presentation_url}`)
|
|
122
122
|
}
|