Skip to content

Commit

Permalink
Merge pull request #123 from mmoss/passthrough-puppeteer-opts
Browse files Browse the repository at this point in the history
Allow passthrough of puppeteer options
  • Loading branch information
hbi99 authored Jun 17, 2020
2 parents 59f09e5 + 0d7f0a0 commit 6741e38
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@

const defiant = {
init: async () => {
init: async (puppeteerOpts) => {
const puppeteer = require('puppeteer')
const fs = require('fs')
const script = fs.readFileSync(__dirname +'/dist/defiant.min.js', 'utf8')

return new Promise((resolve, reject) => {
puppeteer
.launch()
.launch(puppeteerOpts)
.then(async browser => {
const page = await browser.newPage()
page.on('console', msg => console.log(msg.text()))
Expand Down

0 comments on commit 6741e38

Please sign in to comment.