Skip to content

Commit

Permalink
Merge pull request #5 from omnihound/master
Browse files Browse the repository at this point in the history
allow options to also accept command line arguments. Resolves #4
  • Loading branch information
KoryNunn authored Apr 9, 2018
2 parents 14c7073 + fd5419c commit 5023cf9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ var fs = require('fs'),
rm = require('rimraf'),
findShallowestFile = require('find-shallow-file');


function openUrl(page, uri, callback){
var opened = righto.from(page.goto(uri, { waitUntil: 'networkidle2' }));

Expand Down Expand Up @@ -47,7 +48,7 @@ function render(documentPath, options, callback){
uri = righto(getShallowestHTMLUri, shallowestHTMLFile);

var launchOptions = {
args: ['--no-sandbox', '--disable-setuid-sandbox']
args: ['--no-sandbox', '--disable-setuid-sandbox'].concat(options.args || [])
};

if(options.executablePath){
Expand Down

0 comments on commit 5023cf9

Please sign in to comment.