Run headless chromium with --hide-scrollbars

This patch runs chromium in headless mode with the --hide-scrollbars
flag so that it doesn't spoil screenshots.

Fixes #68.
This commit is contained in:
Andrey Lushnikov 2017-07-10 18:58:29 -07:00
parent 50d9c186b5
commit b6d0ebfbf2
2 changed files with 1 additions and 5 deletions

View File

@ -50,6 +50,7 @@ class Browser {
this._chromeArguments.push(...[
`--headless`,
`--disable-gpu`,
`--hide-scrollbars`,
]);
}
if (typeof options.executablePath === 'string') {

View File

@ -28,11 +28,6 @@ document.addEventListener('DOMContentLoaded', function() {
<style>
/* Hide scrollbar so that it is not captured on screenshots */
::-webkit-scrollbar {
display: none;
}
body {
margin: 0;
padding: 0;