@browserless/lighthouse 10.7.10 → 10.7.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@browserless/lighthouse",
3
3
  "description": "Browserless Lighthouse integration using puppeteer.",
4
4
  "homepage": "https://browserless.js.org",
5
- "version": "10.7.10",
5
+ "version": "10.7.13",
6
6
  "main": "src",
7
7
  "repository": {
8
8
  "type": "git",
@@ -24,10 +24,10 @@
24
24
  "stats"
25
25
  ],
26
26
  "dependencies": {
27
- "lighthouse": "~12.6.0"
27
+ "lighthouse": "~12.8.1"
28
28
  },
29
29
  "devDependencies": {
30
- "@browserless/test": "^10.7.10",
30
+ "@browserless/test": "^10.7.13",
31
31
  "ava": "5"
32
32
  },
33
33
  "engines": {
@@ -45,5 +45,5 @@
45
45
  "timeout": "2m",
46
46
  "workerThreads": false
47
47
  },
48
- "gitHead": "ed927a9e39f1ae3531776665208fa4a6e87b0c49"
48
+ "gitHead": "9ed950add1325d6f93d072d6475f1603e4b97d45"
49
49
  }
package/src/index.js CHANGED
@@ -5,12 +5,13 @@ const getConfig = require('./get-config')
5
5
 
6
6
  module.exports =
7
7
  getBrowserless =>
8
- async (url, { output = 'json', timeout, ...opts } = {}) => {
8
+ async (url, { output = 'json', timeout, flags, ...opts } = {}) => {
9
9
  let teardown
10
10
  const browserless = await getBrowserless(fn => (teardown = fn))
11
11
 
12
12
  const fn = page => async () =>
13
13
  lighthouse({
14
+ flags,
14
15
  config: await getConfig({ ...opts, output }),
15
16
  page,
16
17
  url
package/src/lighthouse.js CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  const lighthouse = require('lighthouse/core/index.cjs')
4
4
 
5
- module.exports = async ({ url, config, page }) => {
6
- const { lhr, report } = await lighthouse(url, undefined, config, page)
5
+ module.exports = async ({ url, config, flags, page }) => {
6
+ const { lhr, report } = await lighthouse(url, flags, config, page)
7
7
  return config.settings.output === 'json' ? lhr : report
8
8
  }