fix(webkit): pass --headless only on Mac

This commit is contained in:
Yury Semikhatsky 2019-12-04 15:33:12 -08:00
parent fc5898892b
commit 46c31db12f

View file

@ -77,7 +77,8 @@ export class Launcher {
else else
stdio = ['ignore', 'ignore', 'ignore', 'pipe', 'pipe']; stdio = ['ignore', 'ignore', 'ignore', 'pipe', 'pipe'];
webkitArguments.push('--inspector-pipe'); webkitArguments.push('--inspector-pipe');
if (options.headless !== false) // Headless options is only implemented on Mac at the moment.
if (process.platform === 'darwin' && options.headless !== false)
webkitArguments.push('--headless'); webkitArguments.push('--headless');
const webkitProcess = childProcess.spawn( const webkitProcess = childProcess.spawn(
webkitExecutable, webkitExecutable,