lib/grover.rb in grover-0.9.1 vs lib/grover.rb in grover-0.9.2

- old
+ new

@@ -110,9 +110,15 @@ } else { await page.emulateMedia(emulateMedia); } } + // If specified, evaluate script on the page + const executeScript = options.executeScript; delete options.executeScript; + if (executeScript != undefined) { + await page.evaluate(executeScript); + } + // If we're running puppeteer in headless mode, return the converted PDF if (debug == undefined || (typeof debug === 'object' && (debug.headless == undefined || debug.headless))) { return await page.#{convert_action}(options); } } finally {