From f5cda274dbb2ef87ddbdcb9c2fc755422ffd061c Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Thu, 1 Jul 2021 21:09:21 -0700 Subject: [PATCH 01/36] wip --- build/build-bundle.js | 42 +- clients/devtools-entry.js | 15 +- clients/devtools-report-assets.js | 2 +- clients/package.json | 1 + lighthouse-core/config/config.js | 2 +- .../config/{ => tmpdir}/config-helpers.js | 12 +- lighthouse-core/fraggle-rock/config/config.js | 2 +- package.json | 11 + yarn.lock | 1104 ++++++++++++++++- 9 files changed, 1166 insertions(+), 25 deletions(-) create mode 100644 clients/package.json rename lighthouse-core/config/{ => tmpdir}/config-helpers.js (98%) diff --git a/build/build-bundle.js b/build/build-bundle.js index c2937508128e..b5cf17a057f6 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -17,6 +17,7 @@ const mkdir = fs.promises.mkdir; const LighthouseRunner = require('../lighthouse-core/runner.js'); const exorcist = require('exorcist'); const browserify = require('browserify'); +const babelify = require('babelify'); const terser = require('terser'); const {minifyFileTransform} = require('./build-utils.js'); const {LH_ROOT} = require('../root.js'); @@ -64,6 +65,7 @@ async function browserifyFile(entryPath, distPath) { pkg: Object.assign({COMMIT_HASH}, require('../package.json')), file: require.resolve('./banner.txt'), }) + .transform(babelify, {presets: [['@babel/preset-env']]}) // Transform the fs.readFile etc into inline strings. .transform('@wardpeet/brfs', { readFileSyncTransform: minifyFileTransform, @@ -183,8 +185,44 @@ async function minifyScript(filePath) { * @return {Promise} */ async function build(entryPath, distPath) { - await browserifyFile(entryPath, distPath); - await minifyScript(distPath); + const rollup = require('rollup'); + // const {terser} = require('rollup-plugin-terser'); + // Only needed b/c getFilenamePrefix loads a commonjs module. + const commonjs = + // @ts-expect-error types are wrong. + /** @type {import('rollup-plugin-commonjs').default} */ (require('rollup-plugin-commonjs')); + + const bundle = await rollup.rollup({ + input: entryPath, + plugins: [ + require('rollup-plugin-shim')({ + [LH_ROOT + '/root.js']: 'export default {LH_ROOT: "."}', + './lighthouse-core/lib/i18n/locales.js': 'export default {}', + 'debug/node': 'export default {}', + 'intl-pluralrules': 'export default {}', + 'intl': 'export default {}', + 'lighthouse-logger': 'export default {}', + 'pako/lib/zlib/inflate.js': 'export default {}', + 'raven': 'export default {}', + 'source-map': 'export default {}', + 'ws': 'export default {}', + }), + commonjs(), + // require('rollup-plugin-node-globals')(), + // terser(), + require('@rollup/plugin-json')(), + require("rollup-plugin-node-resolve")({preferBuiltins: true}), + require('rollup-plugin-node-polyfills')(), + ], + }); + + await bundle.write({ + file: distPath, + format: 'iife', + }); + + // await browserifyFile(entryPath, distPath); + // await minifyScript(distPath); } /** diff --git a/clients/devtools-entry.js b/clients/devtools-entry.js index 305e76220f3e..647627c5dca8 100644 --- a/clients/devtools-entry.js +++ b/clients/devtools-entry.js @@ -5,11 +5,13 @@ */ 'use strict'; -const lighthouse = require('../lighthouse-core/index.js'); -const RawProtocol = require('../lighthouse-core/gather/connections/raw.js'); -const log = require('lighthouse-logger'); -const {registerLocaleData, lookupLocale} = require('../lighthouse-core/lib/i18n/i18n.js'); -const constants = require('../lighthouse-core/config/constants.js'); +import * as lighthouse from '../lighthouse-core/index.js'; +import * as RawProtocol from '../lighthouse-core/gather/connections/raw.js'; +import * as log from 'lighthouse-logger'; +import {registerLocaleData, lookupLocale} from '../lighthouse-core/lib/i18n/i18n.js'; +import * as constants from '../lighthouse-core/config/constants.js'; + +import * as configHelpers from '../lighthouse-core/config/tmpdir/config-helpers.js'; /** @typedef {import('../lighthouse-core/gather/connections/connection.js')} Connection */ @@ -87,3 +89,6 @@ if (typeof self !== 'undefined') { // @ts-expect-error self.lookupLocale = lookupLocale; } + + +console.log(configHelpers.resolveModulePath('./audits/viewport.js')); diff --git a/clients/devtools-report-assets.js b/clients/devtools-report-assets.js index d980ed47a4d1..aaec19e5fe71 100644 --- a/clients/devtools-report-assets.js +++ b/clients/devtools-report-assets.js @@ -20,7 +20,7 @@ const cachedResources = globalThis.EXPORTED_CACHED_RESOURCES_ONLY_FOR_LIGHTHOUSE // resources after this module is resolved. These properties are not // read from immediately, so we can defer reading with getters and everything // is going to be OK. -module.exports = { +export default { get REPORT_CSS() { return cachedResources.get('third_party/lighthouse/report-assets/report.css'); }, diff --git a/clients/package.json b/clients/package.json new file mode 100644 index 000000000000..1632c2c4df68 --- /dev/null +++ b/clients/package.json @@ -0,0 +1 @@ +{"type": "module"} \ No newline at end of file diff --git a/lighthouse-core/config/config.js b/lighthouse-core/config/config.js index 43b608ac886c..da1689837991 100644 --- a/lighthouse-core/config/config.js +++ b/lighthouse-core/config/config.js @@ -22,7 +22,7 @@ const { resolveModulePath, deepClone, deepCloneConfigJson, -} = require('./config-helpers.js'); +} = require('./tmpdir/config-helpers.js'); /** @typedef {typeof import('../gather/gatherers/gatherer.js')} GathererConstructor */ /** @typedef {InstanceType} Gatherer */ diff --git a/lighthouse-core/config/config-helpers.js b/lighthouse-core/config/tmpdir/config-helpers.js similarity index 98% rename from lighthouse-core/config/config-helpers.js rename to lighthouse-core/config/tmpdir/config-helpers.js index 18a47299094d..7c461e5fca10 100644 --- a/lighthouse-core/config/config-helpers.js +++ b/lighthouse-core/config/tmpdir/config-helpers.js @@ -7,13 +7,13 @@ const path = require('path'); const isDeepEqual = require('lodash.isequal'); -const constants = require('./constants.js'); -const Budget = require('./budget.js'); -const Audit = require('../audits/audit.js'); -const Runner = require('../runner.js'); -const i18n = require('../lib/i18n/i18n.js'); +const constants = require('../constants.js'); +const Budget = require('../budget.js'); +const Audit = require('../../audits/audit.js'); +const Runner = require('../../runner.js'); +const i18n = require('../../lib/i18n/i18n.js'); -/** @typedef {typeof import('../gather/gatherers/gatherer.js')} GathererConstructor */ +/** @typedef {typeof import('../../gather/gatherers/gatherer.js')} GathererConstructor */ /** @typedef {InstanceType} Gatherer */ /** diff --git a/lighthouse-core/fraggle-rock/config/config.js b/lighthouse-core/fraggle-rock/config/config.js index db07e6a28891..154f2ca48b5e 100644 --- a/lighthouse-core/fraggle-rock/config/config.js +++ b/lighthouse-core/fraggle-rock/config/config.js @@ -23,7 +23,7 @@ const { resolveSettings, resolveAuditsToDefns, resolveGathererToDefn, -} = require('../../config/config-helpers.js'); +} = require('../../config/tmpdir/config-helpers.js'); const defaultConfigPath = path.join(__dirname, './default-config.js'); /** diff --git a/package.json b/package.json index 0413e87e7734..b80d55e4baae 100644 --- a/package.json +++ b/package.json @@ -88,10 +88,13 @@ "serve-viewer": "yarn serve-gh-pages" }, "devDependencies": { + "@babel/preset-env": "^7.14.7", "@build-tracker/cli": "^1.0.0-beta.15", "@firebase/app-types": "0.3.1", "@firebase/auth-types": "0.3.2", "@firebase/util": "0.2.1", + "@rollup/plugin-dynamic-import-vars": "^1.1.1", + "@rollup/plugin-json": "^4.1.0", "@types/archiver": "^2.1.2", "@types/browserify": "^12.0.36", "@types/chrome": "^0.0.60", @@ -122,6 +125,7 @@ "@wardpeet/brfs": "2.1.0", "angular": "^1.7.4", "archiver": "^3.0.0", + "babelify": "^10.0.0", "browserify": "^17.0.0", "browserify-banner": "^1.0.15", "bundle-phobia-cli": "^0.14.6", @@ -154,6 +158,12 @@ "pako": "^2.0.3", "pretty-json-stringify": "^0.0.2", "puppeteer": "^9.1.1", + "rollup-plugin-commonjs": "^10.1.0", + "rollup-plugin-ignore": "^1.0.9", + "rollup-plugin-node-globals": "^1.4.0", + "rollup-plugin-node-polyfills": "^0.2.1", + "rollup-plugin-node-resolve": "^5.2.0", + "rollup-plugin-shim": "^1.0.0", "tabulator-tables": "^4.9.3", "terser": "^5.3.8", "typed-query-selector": "^2.4.0", @@ -184,6 +194,7 @@ "ps-list": "^7.2.0", "raven": "^2.2.1", "robots-parser": "^2.0.1", + "rollup": "^2.52.6", "semver": "^5.3.0", "speedline-core": "^1.4.3", "third-party-web": "^0.12.2", diff --git a/yarn.lock b/yarn.lock index 119315badee7..8febcc8e4899 100644 --- a/yarn.lock +++ b/yarn.lock @@ -16,6 +16,18 @@ dependencies: "@babel/highlight" "^7.12.13" +"@babel/code-frame@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.14.5.tgz#23b08d740e83f49c5e59945fbf1b43e80bbf4edb" + integrity sha512-9pzDqyc6OLDaqe+zbACgFkb6fKMNG6CObKpnYXChRsvYGyEdc7CA2BaqeOM+vOtCS5ndmJicPJhKAwYRI6UfFw== + dependencies: + "@babel/highlight" "^7.14.5" + +"@babel/compat-data@^7.13.11", "@babel/compat-data@^7.14.5", "@babel/compat-data@^7.14.7": + version "7.14.7" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.14.7.tgz#7b047d7a3a89a67d2258dc61f604f098f1bc7e08" + integrity sha512-nS6dZaISCXJ3+518CWiBfEr//gHyMO02uDxBkXTKZDN5POruCnOZ1N4YBRZDCabwF8nZMWBpRxIicmXtBs+fvw== + "@babel/compat-data@^7.13.12": version "7.13.15" resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.13.15.tgz#7e8eea42d0b64fda2b375b22d06c605222e848f4" @@ -95,6 +107,40 @@ jsesc "^2.5.1" source-map "^0.5.0" +"@babel/generator@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.14.5.tgz#848d7b9f031caca9d0cd0af01b063f226f52d785" + integrity sha512-y3rlP+/G25OIX3mYKKIOlQRcqj7YgrvHxOLbVmyLJ9bPmi5ttvUmpydVjcFjZphOktWuA7ovbx91ECloWTfjIA== + dependencies: + "@babel/types" "^7.14.5" + jsesc "^2.5.1" + source-map "^0.5.0" + +"@babel/helper-annotate-as-pure@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.14.5.tgz#7bf478ec3b71726d56a8ca5775b046fc29879e61" + integrity sha512-EivH9EgBIb+G8ij1B2jAwSH36WnGvkQSEC6CkX/6v6ZFlw5fVOHvsgGF4uiEHO2GzMvunZb6tDLQEQSdrdocrA== + dependencies: + "@babel/types" "^7.14.5" + +"@babel/helper-builder-binary-assignment-operator-visitor@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.14.5.tgz#b939b43f8c37765443a19ae74ad8b15978e0a191" + integrity sha512-YTA/Twn0vBXDVGJuAX6PwW7x5zQei1luDDo2Pl6q1qZ7hVNl0RZrhHCQG/ArGpR29Vl7ETiB8eJyrvpuRp300w== + dependencies: + "@babel/helper-explode-assignable-expression" "^7.14.5" + "@babel/types" "^7.14.5" + +"@babel/helper-compilation-targets@^7.13.0", "@babel/helper-compilation-targets@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.14.5.tgz#7a99c5d0967911e972fe2c3411f7d5b498498ecf" + integrity sha512-v+QtZqXEiOnpO6EYvlImB6zCD2Lel06RzOPzmkz/D/XgQiUu3C/Jb1LOqSt/AIA34TYi/Q+KlT8vTQrgdxkbLw== + dependencies: + "@babel/compat-data" "^7.14.5" + "@babel/helper-validator-option" "^7.14.5" + browserslist "^4.16.6" + semver "^6.3.0" + "@babel/helper-compilation-targets@^7.13.13": version "7.13.13" resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.13.13.tgz#2b2972a0926474853f41e4adbc69338f520600e5" @@ -115,6 +161,47 @@ browserslist "^4.16.6" semver "^6.3.0" +"@babel/helper-create-class-features-plugin@^7.14.5": + version "7.14.6" + resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.14.6.tgz#f114469b6c06f8b5c59c6c4e74621f5085362542" + integrity sha512-Z6gsfGofTxH/+LQXqYEK45kxmcensbzmk/oi8DmaQytlQCgqNZt9XQF8iqlI/SeXWVjaMNxvYvzaYw+kh42mDg== + dependencies: + "@babel/helper-annotate-as-pure" "^7.14.5" + "@babel/helper-function-name" "^7.14.5" + "@babel/helper-member-expression-to-functions" "^7.14.5" + "@babel/helper-optimise-call-expression" "^7.14.5" + "@babel/helper-replace-supers" "^7.14.5" + "@babel/helper-split-export-declaration" "^7.14.5" + +"@babel/helper-create-regexp-features-plugin@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.14.5.tgz#c7d5ac5e9cf621c26057722fb7a8a4c5889358c4" + integrity sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A== + dependencies: + "@babel/helper-annotate-as-pure" "^7.14.5" + regexpu-core "^4.7.1" + +"@babel/helper-define-polyfill-provider@^0.2.2": + version "0.2.3" + resolved "https://registry.yarnpkg.com/@babel/helper-define-polyfill-provider/-/helper-define-polyfill-provider-0.2.3.tgz#0525edec5094653a282688d34d846e4c75e9c0b6" + integrity sha512-RH3QDAfRMzj7+0Nqu5oqgO5q9mFtQEVvCRsi8qCEfzLR9p2BHfn5FzhSB2oj1fF7I2+DcTORkYaQ6aTR9Cofew== + dependencies: + "@babel/helper-compilation-targets" "^7.13.0" + "@babel/helper-module-imports" "^7.12.13" + "@babel/helper-plugin-utils" "^7.13.0" + "@babel/traverse" "^7.13.0" + debug "^4.1.1" + lodash.debounce "^4.0.8" + resolve "^1.14.2" + semver "^6.1.2" + +"@babel/helper-explode-assignable-expression@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.14.5.tgz#8aa72e708205c7bb643e45c73b4386cdf2a1f645" + integrity sha512-Htb24gnGJdIGT4vnRKMdoXiOIlqOLmdiUYpAQ0mYfgVT/GDm8GOYhgi4GL+hMKrkiPRohO4ts34ELFsGAPQLDQ== + dependencies: + "@babel/types" "^7.14.5" + "@babel/helper-function-name@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.12.13.tgz#93ad656db3c3c2232559fd7b2c3dbdcbe0eb377a" @@ -133,6 +220,15 @@ "@babel/template" "^7.12.13" "@babel/types" "^7.14.2" +"@babel/helper-function-name@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.14.5.tgz#89e2c474972f15d8e233b52ee8c480e2cfcd50c4" + integrity sha512-Gjna0AsXWfFvrAuX+VKcN/aNNWonizBj39yGwUzVDVTlMYJMK2Wp6xdpy72mfArFq5uK+NOuexfzZlzI1z9+AQ== + dependencies: + "@babel/helper-get-function-arity" "^7.14.5" + "@babel/template" "^7.14.5" + "@babel/types" "^7.14.5" + "@babel/helper-get-function-arity@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.12.13.tgz#bc63451d403a3b3082b97e1d8b3fe5bd4091e583" @@ -140,6 +236,20 @@ dependencies: "@babel/types" "^7.12.13" +"@babel/helper-get-function-arity@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.14.5.tgz#25fbfa579b0937eee1f3b805ece4ce398c431815" + integrity sha512-I1Db4Shst5lewOM4V+ZKJzQ0JGGaZ6VY1jYvMghRjqs6DWgxLCIyFt30GlnKkfUeFLpJt2vzbMVEXVSXlIFYUg== + dependencies: + "@babel/types" "^7.14.5" + +"@babel/helper-hoist-variables@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.14.5.tgz#e0dd27c33a78e577d7c8884916a3e7ef1f7c7f8d" + integrity sha512-R1PXiz31Uc0Vxy4OEOm07x0oSjKAdPPCh3tPivn/Eo8cvz6gveAeuyUUPB21Hoiif0uoPQSSdhIPS3352nvdyQ== + dependencies: + "@babel/types" "^7.14.5" + "@babel/helper-member-expression-to-functions@^7.13.12": version "7.13.12" resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.13.12.tgz#dfe368f26d426a07299d8d6513821768216e6d72" @@ -147,6 +257,20 @@ dependencies: "@babel/types" "^7.13.12" +"@babel/helper-member-expression-to-functions@^7.14.5": + version "7.14.7" + resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.14.7.tgz#97e56244beb94211fe277bd818e3a329c66f7970" + integrity sha512-TMUt4xKxJn6ccjcOW7c4hlwyJArizskAhoSTOCkA0uZ+KghIaci0Qg9R043kUMWI9mtQfgny+NQ5QATnZ+paaA== + dependencies: + "@babel/types" "^7.14.5" + +"@babel/helper-module-imports@^7.12.13", "@babel/helper-module-imports@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.14.5.tgz#6d1a44df6a38c957aa7c312da076429f11b422f3" + integrity sha512-SwrNHu5QWS84XlHwGYPDtCxcA0hrSlL2yhWYLgeOc0w7ccOl2qv4s/nARI0aYZW+bSwAL5CukeXA47B/1NKcnQ== + dependencies: + "@babel/types" "^7.14.5" + "@babel/helper-module-imports@^7.13.12": version "7.13.12" resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.13.12.tgz#c6a369a6f3621cb25da014078684da9196b61977" @@ -182,6 +306,20 @@ "@babel/traverse" "^7.14.2" "@babel/types" "^7.14.2" +"@babel/helper-module-transforms@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.14.5.tgz#7de42f10d789b423eb902ebd24031ca77cb1e10e" + integrity sha512-iXpX4KW8LVODuAieD7MzhNjmM6dzYY5tfRqT+R9HDXWl0jPn/djKmA+G9s/2C2T9zggw5tK1QNqZ70USfedOwA== + dependencies: + "@babel/helper-module-imports" "^7.14.5" + "@babel/helper-replace-supers" "^7.14.5" + "@babel/helper-simple-access" "^7.14.5" + "@babel/helper-split-export-declaration" "^7.14.5" + "@babel/helper-validator-identifier" "^7.14.5" + "@babel/template" "^7.14.5" + "@babel/traverse" "^7.14.5" + "@babel/types" "^7.14.5" + "@babel/helper-optimise-call-expression@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.12.13.tgz#5c02d171b4c8615b1e7163f888c1c81c30a2aaea" @@ -189,11 +327,32 @@ dependencies: "@babel/types" "^7.12.13" +"@babel/helper-optimise-call-expression@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.14.5.tgz#f27395a8619e0665b3f0364cddb41c25d71b499c" + integrity sha512-IqiLIrODUOdnPU9/F8ib1Fx2ohlgDhxnIDU7OEVi+kAbEZcyiF7BLU8W6PfvPi9LzztjS7kcbzbmL7oG8kD6VA== + dependencies: + "@babel/types" "^7.14.5" + "@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.8.0": version "7.13.0" resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.13.0.tgz#806526ce125aed03373bc416a828321e3a6a33af" integrity sha512-ZPafIPSwzUlAoWT8DKs1W2VyF2gOWthGd5NGFMsBcMMol+ZhK+EQY/e6V96poa6PA/Bh+C9plWN0hXO1uB8AfQ== +"@babel/helper-plugin-utils@^7.13.0", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.8.3": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.14.5.tgz#5ac822ce97eec46741ab70a517971e443a70c5a9" + integrity sha512-/37qQCE3K0vvZKwoK4XU/irIJQdIfCJuhU5eKnNxpFDsOkgFaUAwbv+RYw6eYgsC0E4hS7r5KqGULUogqui0fQ== + +"@babel/helper-remap-async-to-generator@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.14.5.tgz#51439c913612958f54a987a4ffc9ee587a2045d6" + integrity sha512-rLQKdQU+HYlxBwQIj8dk4/0ENOUEhA/Z0l4hN8BexpvmSMN9oA9EagjnhnDpNsRdWCfjwa4mn/HyBXO9yhQP6A== + dependencies: + "@babel/helper-annotate-as-pure" "^7.14.5" + "@babel/helper-wrap-function" "^7.14.5" + "@babel/types" "^7.14.5" + "@babel/helper-replace-supers@^7.13.12": version "7.13.12" resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.13.12.tgz#6442f4c1ad912502481a564a7386de0c77ff3804" @@ -204,6 +363,16 @@ "@babel/traverse" "^7.13.0" "@babel/types" "^7.13.12" +"@babel/helper-replace-supers@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.14.5.tgz#0ecc0b03c41cd567b4024ea016134c28414abb94" + integrity sha512-3i1Qe9/8x/hCHINujn+iuHy+mMRLoc77b2nI9TB0zjH1hvn9qGlXjWlggdwUcju36PkPCy/lpM7LLUdcTyH4Ow== + dependencies: + "@babel/helper-member-expression-to-functions" "^7.14.5" + "@babel/helper-optimise-call-expression" "^7.14.5" + "@babel/traverse" "^7.14.5" + "@babel/types" "^7.14.5" + "@babel/helper-simple-access@^7.13.12": version "7.13.12" resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.13.12.tgz#dd6c538afb61819d205a012c31792a39c7a5eaf6" @@ -211,6 +380,20 @@ dependencies: "@babel/types" "^7.13.12" +"@babel/helper-simple-access@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.14.5.tgz#66ea85cf53ba0b4e588ba77fc813f53abcaa41c4" + integrity sha512-nfBN9xvmCt6nrMZjfhkl7i0oTV3yxR4/FztsbOASyTvVcoYd0TRHh7eMLdlEcCqobydC0LAF3LtC92Iwxo0wyw== + dependencies: + "@babel/types" "^7.14.5" + +"@babel/helper-skip-transparent-expression-wrappers@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.14.5.tgz#96f486ac050ca9f44b009fbe5b7d394cab3a0ee4" + integrity sha512-dmqZB7mrb94PZSAOYtr+ZN5qt5owZIAgqtoTuqiFbHFtxgEcmQlRJVI+bO++fciBunXtB6MK7HrzrfcAzIz2NQ== + dependencies: + "@babel/types" "^7.14.5" + "@babel/helper-split-export-declaration@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.12.13.tgz#e9430be00baf3e88b0e13e6f9d4eaf2136372b05" @@ -218,6 +401,13 @@ dependencies: "@babel/types" "^7.12.13" +"@babel/helper-split-export-declaration@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.14.5.tgz#22b23a54ef51c2b7605d851930c1976dd0bc693a" + integrity sha512-hprxVPu6e5Kdp2puZUmvOGjaLv9TCe58E/Fl6hRq4YiVQxIcNvuq6uTM2r1mT/oPskuS9CgR+I94sqAYv0NGKA== + dependencies: + "@babel/types" "^7.14.5" + "@babel/helper-validator-identifier@^7.12.11": version "7.12.11" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.12.11.tgz#c9a1f021917dcb5ccf0d4e453e399022981fc9ed" @@ -228,11 +418,31 @@ resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.14.0.tgz#d26cad8a47c65286b15df1547319a5d0bcf27288" integrity sha512-V3ts7zMSu5lfiwWDVWzRDGIN+lnCEUdaXgtVHJgLb1rGaA6jMrtB9EmE7L18foXJIE8Un/A/h6NJfGQp/e1J4A== +"@babel/helper-validator-identifier@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.14.5.tgz#d0f0e277c512e0c938277faa85a3968c9a44c0e8" + integrity sha512-5lsetuxCLilmVGyiLEfoHBRX8UCFD+1m2x3Rj97WrW3V7H3u4RWRXA4evMjImCsin2J2YT0QaVDGf+z8ondbAg== + "@babel/helper-validator-option@^7.12.17": version "7.12.17" resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.12.17.tgz#d1fbf012e1a79b7eebbfdc6d270baaf8d9eb9831" integrity sha512-TopkMDmLzq8ngChwRlyjR6raKD6gMSae4JdYDB8bByKreQgG0RBTuKe9LRxW3wFtUnjxOPRKBDwEH6Mg5KeDfw== +"@babel/helper-validator-option@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.14.5.tgz#6e72a1fff18d5dfcb878e1e62f1a021c4b72d5a3" + integrity sha512-OX8D5eeX4XwcroVW45NMvoYaIuFI+GQpA2a8Gi+X/U/cDUIRsV37qQfF905F0htTRCREQIB4KqPeaveRJUl3Ow== + +"@babel/helper-wrap-function@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.14.5.tgz#5919d115bf0fe328b8a5d63bcb610f51601f2bff" + integrity sha512-YEdjTCq+LNuNS1WfxsDCNpgXkJaIyqco6DAelTUjT4f2KIWC1nBcaCaSdHTBqQVLnTBexBcVcFhLSU1KnYuePQ== + dependencies: + "@babel/helper-function-name" "^7.14.5" + "@babel/template" "^7.14.5" + "@babel/traverse" "^7.14.5" + "@babel/types" "^7.14.5" + "@babel/helpers@^7.13.10": version "7.13.10" resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.13.10.tgz#fd8e2ba7488533cdeac45cc158e9ebca5e3c7df8" @@ -260,6 +470,15 @@ chalk "^2.0.0" js-tokens "^4.0.0" +"@babel/highlight@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.14.5.tgz#6861a52f03966405001f6aa534a01a24d99e8cd9" + integrity sha512-qf9u2WFWVV0MppaL877j2dBtQIDgmidgjGk5VIMw3OadXvYaXn66U1BFlH2t4+t3i+8PhedppRv+i40ABzd+gg== + dependencies: + "@babel/helper-validator-identifier" "^7.14.5" + chalk "^2.0.0" + js-tokens "^4.0.0" + "@babel/parser@^7.1.0", "@babel/parser@^7.12.13", "@babel/parser@^7.13.15": version "7.13.15" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.13.15.tgz#8e66775fb523599acb6a289e12929fa5ab0954d8" @@ -275,6 +494,148 @@ resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.14.4.tgz#a5c560d6db6cd8e6ed342368dea8039232cbab18" integrity sha512-ArliyUsWDUqEGfWcmzpGUzNfLxTdTp6WU4IuP6QFSp9gGfWS6boxFCkJSJ/L4+RG8z/FnIU3WxCk6hPL9SSWeA== +"@babel/parser@^7.14.5", "@babel/parser@^7.14.7": + version "7.14.7" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.14.7.tgz#6099720c8839ca865a2637e6c85852ead0bdb595" + integrity sha512-X67Z5y+VBJuHB/RjwECp8kSl5uYi0BvRbNeWqkaJCVh+LiTPl19WBUfG627psSgp9rSf6ojuXghQM3ha6qHHdA== + +"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.14.5.tgz#4b467302e1548ed3b1be43beae2cc9cf45e0bb7e" + integrity sha512-ZoJS2XCKPBfTmL122iP6NM9dOg+d4lc9fFk3zxc8iDjvt8Pk4+TlsHSKhIPf6X+L5ORCdBzqMZDjL/WHj7WknQ== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-skip-transparent-expression-wrappers" "^7.14.5" + "@babel/plugin-proposal-optional-chaining" "^7.14.5" + +"@babel/plugin-proposal-async-generator-functions@^7.14.7": + version "7.14.7" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.14.7.tgz#784a48c3d8ed073f65adcf30b57bcbf6c8119ace" + integrity sha512-RK8Wj7lXLY3bqei69/cc25gwS5puEc3dknoFPFbqfy3XxYQBQFvu4ioWpafMBAB+L9NyptQK4nMOa5Xz16og8Q== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-remap-async-to-generator" "^7.14.5" + "@babel/plugin-syntax-async-generators" "^7.8.4" + +"@babel/plugin-proposal-class-properties@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.14.5.tgz#40d1ee140c5b1e31a350f4f5eed945096559b42e" + integrity sha512-q/PLpv5Ko4dVc1LYMpCY7RVAAO4uk55qPwrIuJ5QJ8c6cVuAmhu7I/49JOppXL6gXf7ZHzpRVEUZdYoPLM04Gg== + dependencies: + "@babel/helper-create-class-features-plugin" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-proposal-class-static-block@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-static-block/-/plugin-proposal-class-static-block-7.14.5.tgz#158e9e10d449c3849ef3ecde94a03d9f1841b681" + integrity sha512-KBAH5ksEnYHCegqseI5N9skTdxgJdmDoAOc0uXa+4QMYKeZD0w5IARh4FMlTNtaHhbB8v+KzMdTgxMMzsIy6Yg== + dependencies: + "@babel/helper-create-class-features-plugin" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-class-static-block" "^7.14.5" + +"@babel/plugin-proposal-dynamic-import@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.14.5.tgz#0c6617df461c0c1f8fff3b47cd59772360101d2c" + integrity sha512-ExjiNYc3HDN5PXJx+bwC50GIx/KKanX2HiggnIUAYedbARdImiCU4RhhHfdf0Kd7JNXGpsBBBCOm+bBVy3Gb0g== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-dynamic-import" "^7.8.3" + +"@babel/plugin-proposal-export-namespace-from@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.14.5.tgz#dbad244310ce6ccd083072167d8cea83a52faf76" + integrity sha512-g5POA32bXPMmSBu5Dx/iZGLGnKmKPc5AiY7qfZgurzrCYgIztDlHFbznSNCoQuv57YQLnQfaDi7dxCtLDIdXdA== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-export-namespace-from" "^7.8.3" + +"@babel/plugin-proposal-json-strings@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.14.5.tgz#38de60db362e83a3d8c944ac858ddf9f0c2239eb" + integrity sha512-NSq2fczJYKVRIsUJyNxrVUMhB27zb7N7pOFGQOhBKJrChbGcgEAqyZrmZswkPk18VMurEeJAaICbfm57vUeTbQ== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-json-strings" "^7.8.3" + +"@babel/plugin-proposal-logical-assignment-operators@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.14.5.tgz#6e6229c2a99b02ab2915f82571e0cc646a40c738" + integrity sha512-YGn2AvZAo9TwyhlLvCCWxD90Xq8xJ4aSgaX3G5D/8DW94L8aaT+dS5cSP+Z06+rCJERGSr9GxMBZ601xoc2taw== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" + +"@babel/plugin-proposal-nullish-coalescing-operator@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.14.5.tgz#ee38589ce00e2cc59b299ec3ea406fcd3a0fdaf6" + integrity sha512-gun/SOnMqjSb98Nkaq2rTKMwervfdAoz6NphdY0vTfuzMfryj+tDGb2n6UkDKwez+Y8PZDhE3D143v6Gepp4Hg== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" + +"@babel/plugin-proposal-numeric-separator@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.14.5.tgz#83631bf33d9a51df184c2102a069ac0c58c05f18" + integrity sha512-yiclALKe0vyZRZE0pS6RXgjUOt87GWv6FYa5zqj15PvhOGFO69R5DusPlgK/1K5dVnCtegTiWu9UaBSrLLJJBg== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-numeric-separator" "^7.10.4" + +"@babel/plugin-proposal-object-rest-spread@^7.14.7": + version "7.14.7" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.14.7.tgz#5920a2b3df7f7901df0205974c0641b13fd9d363" + integrity sha512-082hsZz+sVabfmDWo1Oct1u1AgbKbUAyVgmX4otIc7bdsRgHBXwTwb3DpDmD4Eyyx6DNiuz5UAATT655k+kL5g== + dependencies: + "@babel/compat-data" "^7.14.7" + "@babel/helper-compilation-targets" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-transform-parameters" "^7.14.5" + +"@babel/plugin-proposal-optional-catch-binding@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.14.5.tgz#939dd6eddeff3a67fdf7b3f044b5347262598c3c" + integrity sha512-3Oyiixm0ur7bzO5ybNcZFlmVsygSIQgdOa7cTfOYCMY+wEPAYhZAJxi3mixKFCTCKUhQXuCTtQ1MzrpL3WT8ZQ== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" + +"@babel/plugin-proposal-optional-chaining@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.14.5.tgz#fa83651e60a360e3f13797eef00b8d519695b603" + integrity sha512-ycz+VOzo2UbWNI1rQXxIuMOzrDdHGrI23fRiz/Si2R4kv2XZQ1BK8ccdHwehMKBlcH/joGW/tzrUmo67gbJHlQ== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-skip-transparent-expression-wrappers" "^7.14.5" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + +"@babel/plugin-proposal-private-methods@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.14.5.tgz#37446495996b2945f30f5be5b60d5e2aa4f5792d" + integrity sha512-838DkdUA1u+QTCplatfq4B7+1lnDa/+QMI89x5WZHBcnNv+47N8QEj2k9I2MUU9xIv8XJ4XvPCviM/Dj7Uwt9g== + dependencies: + "@babel/helper-create-class-features-plugin" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-proposal-private-property-in-object@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-property-in-object/-/plugin-proposal-private-property-in-object-7.14.5.tgz#9f65a4d0493a940b4c01f8aa9d3f1894a587f636" + integrity sha512-62EyfyA3WA0mZiF2e2IV9mc9Ghwxcg8YTu8BS4Wss4Y3PY725OmS9M0qLORbJwLqFtGh+jiE4wAmocK2CTUK2Q== + dependencies: + "@babel/helper-annotate-as-pure" "^7.14.5" + "@babel/helper-create-class-features-plugin" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-private-property-in-object" "^7.14.5" + +"@babel/plugin-proposal-unicode-property-regex@^7.14.5", "@babel/plugin-proposal-unicode-property-regex@^7.4.4": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.14.5.tgz#0f95ee0e757a5d647f378daa0eca7e93faa8bbe8" + integrity sha512-6axIeOU5LnY471KenAB9vI8I5j7NQ2d652hIYwVyRfgaZT5UpiqFKCuVXCDMSrU+3VFafnu2c5m3lrWIlr6A5Q== + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-async-generators@^7.8.4": version "7.8.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" @@ -289,13 +650,34 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-class-properties@^7.8.3": +"@babel/plugin-syntax-class-properties@^7.12.13", "@babel/plugin-syntax-class-properties@^7.8.3": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz#b5c987274c4a3a82b89714796931a6b53544ae10" integrity sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA== dependencies: "@babel/helper-plugin-utils" "^7.12.13" +"@babel/plugin-syntax-class-static-block@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-class-static-block/-/plugin-syntax-class-static-block-7.14.5.tgz#195df89b146b4b78b3bf897fd7a257c84659d406" + integrity sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-dynamic-import@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz#62bf98b2da3cd21d626154fc96ee5b3cb68eacb3" + integrity sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ== + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-export-namespace-from@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-export-namespace-from/-/plugin-syntax-export-namespace-from-7.8.3.tgz#028964a9ba80dbc094c915c487ad7c4e7a66465a" + integrity sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q== + dependencies: + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-import-meta@^7.8.3": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz#ee601348c370fa334d2207be158777496521fd51" @@ -310,7 +692,7 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-logical-assignment-operators@^7.8.3": +"@babel/plugin-syntax-logical-assignment-operators@^7.10.4", "@babel/plugin-syntax-logical-assignment-operators@^7.8.3": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz#ca91ef46303530448b906652bac2e9fe9941f699" integrity sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig== @@ -324,7 +706,7 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-numeric-separator@^7.8.3": +"@babel/plugin-syntax-numeric-separator@^7.10.4", "@babel/plugin-syntax-numeric-separator@^7.8.3": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz#b9b070b3e33570cd9fd07ba7fa91c0dd37b9af97" integrity sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug== @@ -352,6 +734,20 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.0" +"@babel/plugin-syntax-private-property-in-object@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-private-property-in-object/-/plugin-syntax-private-property-in-object-7.14.5.tgz#0dc6671ec0ea22b6e94a1114f857970cd39de1ad" + integrity sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-syntax-top-level-await@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz#c1cfdadc35a646240001f06138247b741c34d94c" + integrity sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/plugin-syntax-top-level-await@^7.8.3": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.12.13.tgz#c5f0fa6e249f5b739727f923540cf7a806130178" @@ -366,6 +762,351 @@ dependencies: "@babel/helper-plugin-utils" "^7.12.13" +"@babel/plugin-transform-arrow-functions@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.14.5.tgz#f7187d9588a768dd080bf4c9ffe117ea62f7862a" + integrity sha512-KOnO0l4+tD5IfOdi4x8C1XmEIRWUjNRV8wc6K2vz/3e8yAOoZZvsRXRRIF/yo/MAOFb4QjtAw9xSxMXbSMRy8A== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-async-to-generator@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.14.5.tgz#72c789084d8f2094acb945633943ef8443d39e67" + integrity sha512-szkbzQ0mNk0rpu76fzDdqSyPu0MuvpXgC+6rz5rpMb5OIRxdmHfQxrktL8CYolL2d8luMCZTR0DpIMIdL27IjA== + dependencies: + "@babel/helper-module-imports" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-remap-async-to-generator" "^7.14.5" + +"@babel/plugin-transform-block-scoped-functions@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.14.5.tgz#e48641d999d4bc157a67ef336aeb54bc44fd3ad4" + integrity sha512-dtqWqdWZ5NqBX3KzsVCWfQI3A53Ft5pWFCT2eCVUftWZgjc5DpDponbIF1+c+7cSGk2wN0YK7HGL/ezfRbpKBQ== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-block-scoping@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.14.5.tgz#8cc63e61e50f42e078e6f09be775a75f23ef9939" + integrity sha512-LBYm4ZocNgoCqyxMLoOnwpsmQ18HWTQvql64t3GvMUzLQrNoV1BDG0lNftC8QKYERkZgCCT/7J5xWGObGAyHDw== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-classes@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.14.5.tgz#0e98e82097b38550b03b483f9b51a78de0acb2cf" + integrity sha512-J4VxKAMykM06K/64z9rwiL6xnBHgB1+FVspqvlgCdwD1KUbQNfszeKVVOMh59w3sztHYIZDgnhOC4WbdEfHFDA== + dependencies: + "@babel/helper-annotate-as-pure" "^7.14.5" + "@babel/helper-function-name" "^7.14.5" + "@babel/helper-optimise-call-expression" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-replace-supers" "^7.14.5" + "@babel/helper-split-export-declaration" "^7.14.5" + globals "^11.1.0" + +"@babel/plugin-transform-computed-properties@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.14.5.tgz#1b9d78987420d11223d41195461cc43b974b204f" + integrity sha512-pWM+E4283UxaVzLb8UBXv4EIxMovU4zxT1OPnpHJcmnvyY9QbPPTKZfEj31EUvG3/EQRbYAGaYEUZ4yWOBC2xg== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-destructuring@^7.14.7": + version "7.14.7" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.14.7.tgz#0ad58ed37e23e22084d109f185260835e5557576" + integrity sha512-0mDE99nK+kVh3xlc5vKwB6wnP9ecuSj+zQCa/n0voENtP/zymdT4HH6QEb65wjjcbqr1Jb/7z9Qp7TF5FtwYGw== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-dotall-regex@^7.14.5", "@babel/plugin-transform-dotall-regex@^7.4.4": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.14.5.tgz#2f6bf76e46bdf8043b4e7e16cf24532629ba0c7a" + integrity sha512-loGlnBdj02MDsFaHhAIJzh7euK89lBrGIdM9EAtHFo6xKygCUGuuWe07o1oZVk287amtW1n0808sQM99aZt3gw== + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-duplicate-keys@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.14.5.tgz#365a4844881bdf1501e3a9f0270e7f0f91177954" + integrity sha512-iJjbI53huKbPDAsJ8EmVmvCKeeq21bAze4fu9GBQtSLqfvzj2oRuHVx4ZkDwEhg1htQ+5OBZh/Ab0XDf5iBZ7A== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-exponentiation-operator@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.14.5.tgz#5154b8dd6a3dfe6d90923d61724bd3deeb90b493" + integrity sha512-jFazJhMBc9D27o9jDnIE5ZErI0R0m7PbKXVq77FFvqFbzvTMuv8jaAwLZ5PviOLSFttqKIW0/wxNSDbjLk0tYA== + dependencies: + "@babel/helper-builder-binary-assignment-operator-visitor" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-for-of@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.14.5.tgz#dae384613de8f77c196a8869cbf602a44f7fc0eb" + integrity sha512-CfmqxSUZzBl0rSjpoQSFoR9UEj3HzbGuGNL21/iFTmjb5gFggJp3ph0xR1YBhexmLoKRHzgxuFvty2xdSt6gTA== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-function-name@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.14.5.tgz#e81c65ecb900746d7f31802f6bed1f52d915d6f2" + integrity sha512-vbO6kv0fIzZ1GpmGQuvbwwm+O4Cbm2NrPzwlup9+/3fdkuzo1YqOZcXw26+YUJB84Ja7j9yURWposEHLYwxUfQ== + dependencies: + "@babel/helper-function-name" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-literals@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.14.5.tgz#41d06c7ff5d4d09e3cf4587bd3ecf3930c730f78" + integrity sha512-ql33+epql2F49bi8aHXxvLURHkxJbSmMKl9J5yHqg4PLtdE6Uc48CH1GS6TQvZ86eoB/ApZXwm7jlA+B3kra7A== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-member-expression-literals@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.14.5.tgz#b39cd5212a2bf235a617d320ec2b48bcc091b8a7" + integrity sha512-WkNXxH1VXVTKarWFqmso83xl+2V3Eo28YY5utIkbsmXoItO8Q3aZxN4BTS2k0hz9dGUloHK26mJMyQEYfkn/+Q== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-modules-amd@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.14.5.tgz#4fd9ce7e3411cb8b83848480b7041d83004858f7" + integrity sha512-3lpOU8Vxmp3roC4vzFpSdEpGUWSMsHFreTWOMMLzel2gNGfHE5UWIh/LN6ghHs2xurUp4jRFYMUIZhuFbody1g== + dependencies: + "@babel/helper-module-transforms" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + babel-plugin-dynamic-import-node "^2.3.3" + +"@babel/plugin-transform-modules-commonjs@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.14.5.tgz#7aaee0ea98283de94da98b28f8c35701429dad97" + integrity sha512-en8GfBtgnydoao2PS+87mKyw62k02k7kJ9ltbKe0fXTHrQmG6QZZflYuGI1VVG7sVpx4E1n7KBpNlPb8m78J+A== + dependencies: + "@babel/helper-module-transforms" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-simple-access" "^7.14.5" + babel-plugin-dynamic-import-node "^2.3.3" + +"@babel/plugin-transform-modules-systemjs@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.14.5.tgz#c75342ef8b30dcde4295d3401aae24e65638ed29" + integrity sha512-mNMQdvBEE5DcMQaL5LbzXFMANrQjd2W7FPzg34Y4yEz7dBgdaC+9B84dSO+/1Wba98zoDbInctCDo4JGxz1VYA== + dependencies: + "@babel/helper-hoist-variables" "^7.14.5" + "@babel/helper-module-transforms" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-validator-identifier" "^7.14.5" + babel-plugin-dynamic-import-node "^2.3.3" + +"@babel/plugin-transform-modules-umd@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.14.5.tgz#fb662dfee697cce274a7cda525190a79096aa6e0" + integrity sha512-RfPGoagSngC06LsGUYyM9QWSXZ8MysEjDJTAea1lqRjNECE3y0qIJF/qbvJxc4oA4s99HumIMdXOrd+TdKaAAA== + dependencies: + "@babel/helper-module-transforms" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-named-capturing-groups-regex@^7.14.7": + version "7.14.7" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.14.7.tgz#60c06892acf9df231e256c24464bfecb0908fd4e" + integrity sha512-DTNOTaS7TkW97xsDMrp7nycUVh6sn/eq22VaxWfEdzuEbRsiaOU0pqU7DlyUGHVsbQbSghvjKRpEl+nUCKGQSg== + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.14.5" + +"@babel/plugin-transform-new-target@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.14.5.tgz#31bdae8b925dc84076ebfcd2a9940143aed7dbf8" + integrity sha512-Nx054zovz6IIRWEB49RDRuXGI4Gy0GMgqG0cII9L3MxqgXz/+rgII+RU58qpo4g7tNEx1jG7rRVH4ihZoP4esQ== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-object-super@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.14.5.tgz#d0b5faeac9e98597a161a9cf78c527ed934cdc45" + integrity sha512-MKfOBWzK0pZIrav9z/hkRqIk/2bTv9qvxHzPQc12RcVkMOzpIKnFCNYJip00ssKWYkd8Sf5g0Wr7pqJ+cmtuFg== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-replace-supers" "^7.14.5" + +"@babel/plugin-transform-parameters@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.14.5.tgz#49662e86a1f3ddccac6363a7dfb1ff0a158afeb3" + integrity sha512-Tl7LWdr6HUxTmzQtzuU14SqbgrSKmaR77M0OKyq4njZLQTPfOvzblNKyNkGwOfEFCEx7KeYHQHDI0P3F02IVkA== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-property-literals@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.14.5.tgz#0ddbaa1f83db3606f1cdf4846fa1dfb473458b34" + integrity sha512-r1uilDthkgXW8Z1vJz2dKYLV1tuw2xsbrp3MrZmD99Wh9vsfKoob+JTgri5VUb/JqyKRXotlOtwgu4stIYCmnw== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-regenerator@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.14.5.tgz#9676fd5707ed28f522727c5b3c0aa8544440b04f" + integrity sha512-NVIY1W3ITDP5xQl50NgTKlZ0GrotKtLna08/uGY6ErQt6VEQZXla86x/CTddm5gZdcr+5GSsvMeTmWA5Ii6pkg== + dependencies: + regenerator-transform "^0.14.2" + +"@babel/plugin-transform-reserved-words@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.14.5.tgz#c44589b661cfdbef8d4300dcc7469dffa92f8304" + integrity sha512-cv4F2rv1nD4qdexOGsRQXJrOcyb5CrgjUH9PKrrtyhSDBNWGxd0UIitjyJiWagS+EbUGjG++22mGH1Pub8D6Vg== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-shorthand-properties@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.14.5.tgz#97f13855f1409338d8cadcbaca670ad79e091a58" + integrity sha512-xLucks6T1VmGsTB+GWK5Pl9Jl5+nRXD1uoFdA5TSO6xtiNjtXTjKkmPdFXVLGlK5A2/or/wQMKfmQ2Y0XJfn5g== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-spread@^7.14.6": + version "7.14.6" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.14.6.tgz#6bd40e57fe7de94aa904851963b5616652f73144" + integrity sha512-Zr0x0YroFJku7n7+/HH3A2eIrGMjbmAIbJSVv0IZ+t3U2WUQUA64S/oeied2e+MaGSjmt4alzBCsK9E8gh+fag== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-skip-transparent-expression-wrappers" "^7.14.5" + +"@babel/plugin-transform-sticky-regex@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.14.5.tgz#5b617542675e8b7761294381f3c28c633f40aeb9" + integrity sha512-Z7F7GyvEMzIIbwnziAZmnSNpdijdr4dWt+FJNBnBLz5mwDFkqIXU9wmBcWWad3QeJF5hMTkRe4dAq2sUZiG+8A== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-template-literals@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.14.5.tgz#a5f2bc233937d8453885dc736bdd8d9ffabf3d93" + integrity sha512-22btZeURqiepOfuy/VkFr+zStqlujWaarpMErvay7goJS6BWwdd6BY9zQyDLDa4x2S3VugxFb162IZ4m/S/+Gg== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-typeof-symbol@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.14.5.tgz#39af2739e989a2bd291bf6b53f16981423d457d4" + integrity sha512-lXzLD30ffCWseTbMQzrvDWqljvZlHkXU+CnseMhkMNqU1sASnCsz3tSzAaH3vCUXb9PHeUb90ZT1BdFTm1xxJw== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-unicode-escapes@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.14.5.tgz#9d4bd2a681e3c5d7acf4f57fa9e51175d91d0c6b" + integrity sha512-crTo4jATEOjxj7bt9lbYXcBAM3LZaUrbP2uUdxb6WIorLmjNKSpHfIybgY4B8SRpbf8tEVIWH3Vtm7ayCrKocA== + dependencies: + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/plugin-transform-unicode-regex@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.14.5.tgz#4cd09b6c8425dd81255c7ceb3fb1836e7414382e" + integrity sha512-UygduJpC5kHeCiRw/xDVzC+wj8VaYSoKl5JNVmbP7MadpNinAm3SvZCxZ42H37KZBKztz46YC73i9yV34d0Tzw== + dependencies: + "@babel/helper-create-regexp-features-plugin" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + +"@babel/preset-env@^7.14.7": + version "7.14.7" + resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.14.7.tgz#5c70b22d4c2d893b03d8c886a5c17422502b932a" + integrity sha512-itOGqCKLsSUl0Y+1nSfhbuuOlTs0MJk2Iv7iSH+XT/mR8U1zRLO7NjWlYXB47yhK4J/7j+HYty/EhFZDYKa/VA== + dependencies: + "@babel/compat-data" "^7.14.7" + "@babel/helper-compilation-targets" "^7.14.5" + "@babel/helper-plugin-utils" "^7.14.5" + "@babel/helper-validator-option" "^7.14.5" + "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining" "^7.14.5" + "@babel/plugin-proposal-async-generator-functions" "^7.14.7" + "@babel/plugin-proposal-class-properties" "^7.14.5" + "@babel/plugin-proposal-class-static-block" "^7.14.5" + "@babel/plugin-proposal-dynamic-import" "^7.14.5" + "@babel/plugin-proposal-export-namespace-from" "^7.14.5" + "@babel/plugin-proposal-json-strings" "^7.14.5" + "@babel/plugin-proposal-logical-assignment-operators" "^7.14.5" + "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" + "@babel/plugin-proposal-numeric-separator" "^7.14.5" + "@babel/plugin-proposal-object-rest-spread" "^7.14.7" + "@babel/plugin-proposal-optional-catch-binding" "^7.14.5" + "@babel/plugin-proposal-optional-chaining" "^7.14.5" + "@babel/plugin-proposal-private-methods" "^7.14.5" + "@babel/plugin-proposal-private-property-in-object" "^7.14.5" + "@babel/plugin-proposal-unicode-property-regex" "^7.14.5" + "@babel/plugin-syntax-async-generators" "^7.8.4" + "@babel/plugin-syntax-class-properties" "^7.12.13" + "@babel/plugin-syntax-class-static-block" "^7.14.5" + "@babel/plugin-syntax-dynamic-import" "^7.8.3" + "@babel/plugin-syntax-export-namespace-from" "^7.8.3" + "@babel/plugin-syntax-json-strings" "^7.8.3" + "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" + "@babel/plugin-syntax-numeric-separator" "^7.10.4" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + "@babel/plugin-syntax-private-property-in-object" "^7.14.5" + "@babel/plugin-syntax-top-level-await" "^7.14.5" + "@babel/plugin-transform-arrow-functions" "^7.14.5" + "@babel/plugin-transform-async-to-generator" "^7.14.5" + "@babel/plugin-transform-block-scoped-functions" "^7.14.5" + "@babel/plugin-transform-block-scoping" "^7.14.5" + "@babel/plugin-transform-classes" "^7.14.5" + "@babel/plugin-transform-computed-properties" "^7.14.5" + "@babel/plugin-transform-destructuring" "^7.14.7" + "@babel/plugin-transform-dotall-regex" "^7.14.5" + "@babel/plugin-transform-duplicate-keys" "^7.14.5" + "@babel/plugin-transform-exponentiation-operator" "^7.14.5" + "@babel/plugin-transform-for-of" "^7.14.5" + "@babel/plugin-transform-function-name" "^7.14.5" + "@babel/plugin-transform-literals" "^7.14.5" + "@babel/plugin-transform-member-expression-literals" "^7.14.5" + "@babel/plugin-transform-modules-amd" "^7.14.5" + "@babel/plugin-transform-modules-commonjs" "^7.14.5" + "@babel/plugin-transform-modules-systemjs" "^7.14.5" + "@babel/plugin-transform-modules-umd" "^7.14.5" + "@babel/plugin-transform-named-capturing-groups-regex" "^7.14.7" + "@babel/plugin-transform-new-target" "^7.14.5" + "@babel/plugin-transform-object-super" "^7.14.5" + "@babel/plugin-transform-parameters" "^7.14.5" + "@babel/plugin-transform-property-literals" "^7.14.5" + "@babel/plugin-transform-regenerator" "^7.14.5" + "@babel/plugin-transform-reserved-words" "^7.14.5" + "@babel/plugin-transform-shorthand-properties" "^7.14.5" + "@babel/plugin-transform-spread" "^7.14.6" + "@babel/plugin-transform-sticky-regex" "^7.14.5" + "@babel/plugin-transform-template-literals" "^7.14.5" + "@babel/plugin-transform-typeof-symbol" "^7.14.5" + "@babel/plugin-transform-unicode-escapes" "^7.14.5" + "@babel/plugin-transform-unicode-regex" "^7.14.5" + "@babel/preset-modules" "^0.1.4" + "@babel/types" "^7.14.5" + babel-plugin-polyfill-corejs2 "^0.2.2" + babel-plugin-polyfill-corejs3 "^0.2.2" + babel-plugin-polyfill-regenerator "^0.2.2" + core-js-compat "^3.15.0" + semver "^6.3.0" + +"@babel/preset-modules@^0.1.4": + version "0.1.4" + resolved "https://registry.yarnpkg.com/@babel/preset-modules/-/preset-modules-0.1.4.tgz#362f2b68c662842970fdb5e254ffc8fc1c2e415e" + integrity sha512-J36NhwnfdzpmH41M1DrnkkgAqhZaqr/NBdPfQ677mLzlaXo+oDiv1deyCDtgAhz8p328otdob0Du7+xgHGZbKg== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/plugin-proposal-unicode-property-regex" "^7.4.4" + "@babel/plugin-transform-dotall-regex" "^7.4.4" + "@babel/types" "^7.4.4" + esutils "^2.0.2" + +"@babel/runtime@^7.8.4": + version "7.14.6" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.14.6.tgz#535203bc0892efc7dec60bdc27b2ecf6e409062d" + integrity sha512-/PCB2uJ7oM44tz8YhC4Z/6PeOKXp4K588f+5M3clr1M4zbqztlo0XEfJ2LEzj/FgwfgGcIdl8n7YYjTCI0BYwg== + dependencies: + regenerator-runtime "^0.13.4" + "@babel/template@^7.12.13", "@babel/template@^7.3.3": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.12.13.tgz#530265be8a2589dbb37523844c5bcb55947fb327" @@ -375,6 +1116,15 @@ "@babel/parser" "^7.12.13" "@babel/types" "^7.12.13" +"@babel/template@^7.14.5": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.14.5.tgz#a9bc9d8b33354ff6e55a9c60d1109200a68974f4" + integrity sha512-6Z3Po85sfxRGachLULUhOmvAaOo7xCvqGQtxINai2mEGPFm6pQ4z5QInFnUrRpfoSV60BnjyF5F3c+15fxFV1g== + dependencies: + "@babel/code-frame" "^7.14.5" + "@babel/parser" "^7.14.5" + "@babel/types" "^7.14.5" + "@babel/traverse@^7.1.0", "@babel/traverse@^7.13.0", "@babel/traverse@^7.13.13", "@babel/traverse@^7.13.15": version "7.13.15" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.13.15.tgz#c38bf7679334ddd4028e8e1f7b3aa5019f0dada7" @@ -403,6 +1153,21 @@ debug "^4.1.0" globals "^11.1.0" +"@babel/traverse@^7.14.5": + version "7.14.7" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.14.7.tgz#64007c9774cfdc3abd23b0780bc18a3ce3631753" + integrity sha512-9vDr5NzHu27wgwejuKL7kIOm4bwEtaPQ4Z6cpCmjSuaRqpH/7xc4qcGEscwMqlkwgcXl6MvqoAjZkQ24uSdIZQ== + dependencies: + "@babel/code-frame" "^7.14.5" + "@babel/generator" "^7.14.5" + "@babel/helper-function-name" "^7.14.5" + "@babel/helper-hoist-variables" "^7.14.5" + "@babel/helper-split-export-declaration" "^7.14.5" + "@babel/parser" "^7.14.7" + "@babel/types" "^7.14.5" + debug "^4.1.0" + globals "^11.1.0" + "@babel/traverse@^7.7.2": version "7.14.0" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.14.0.tgz#cea0dc8ae7e2b1dec65f512f39f3483e8cc95aef" @@ -442,6 +1207,14 @@ "@babel/helper-validator-identifier" "^7.14.0" to-fast-properties "^2.0.0" +"@babel/types@^7.14.5", "@babel/types@^7.4.4": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.14.5.tgz#3bb997ba829a2104cedb20689c4a5b8121d383ff" + integrity sha512-M/NzBpEL95I5Hh4dwhin5JlE7EzO5PHMAuzjxss3tiOBD46KfQvVedN/3jEPZvdRvtsK2222XfdHogNIttFgcg== + dependencies: + "@babel/helper-validator-identifier" "^7.14.5" + to-fast-properties "^2.0.0" + "@bcoe/v8-coverage@^0.2.3": version "0.2.3" resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" @@ -742,6 +1515,32 @@ "@nodelib/fs.scandir" "2.1.3" fastq "^1.6.0" +"@rollup/plugin-dynamic-import-vars@^1.1.1": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@rollup/plugin-dynamic-import-vars/-/plugin-dynamic-import-vars-1.1.1.tgz#d72142fd9e450bcf5e17624adf4f4d4c25d7daec" + integrity sha512-PqdfEKlsyPx0hPSSuOigCHgrQbOLW+y09KRRCFeWiBBnkuh4LlV6mfrDefmLQijj8XCWzyLct2rK+q89qvRp7A== + dependencies: + "@rollup/pluginutils" "^3.1.0" + estree-walker "^2.0.1" + globby "^11.0.1" + magic-string "^0.25.7" + +"@rollup/plugin-json@^4.1.0": + version "4.1.0" + resolved "https://registry.yarnpkg.com/@rollup/plugin-json/-/plugin-json-4.1.0.tgz#54e09867ae6963c593844d8bd7a9c718294496f3" + integrity sha512-yfLbTdNS6amI/2OpmbiBoW12vngr5NW2jCJVZSBEz+H5KfUJZ2M7sDjk0U6GOOdCWFVScShte29o9NezJ53TPw== + dependencies: + "@rollup/pluginutils" "^3.0.8" + +"@rollup/pluginutils@^3.0.8", "@rollup/pluginutils@^3.1.0": + version "3.1.0" + resolved "https://registry.yarnpkg.com/@rollup/pluginutils/-/pluginutils-3.1.0.tgz#706b4524ee6dc8b103b3c995533e5ad680c02b9b" + integrity sha512-GksZ6pr6TpIjHm8h9lSQ8pi8BE9VeubNT0OMJ3B5uZJ8pz73NPiqOtCog/x2/QzM1ENChPKxMDhiQuRHsqc+lg== + dependencies: + "@types/estree" "0.0.39" + estree-walker "^1.0.1" + picomatch "^2.2.2" + "@sindresorhus/is@^0.14.0": version "0.14.0" resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-0.14.0.tgz#9fb3a3cf3132328151f353de4632e01e52102bea" @@ -871,7 +1670,7 @@ "@types/estree" "*" "@types/json-schema" "*" -"@types/estree@*": +"@types/estree@*", "@types/estree@0.0.39": version "0.0.39" resolved "https://registry.yarnpkg.com/@types/estree/-/estree-0.0.39.tgz#e177e699ee1b8c22d23174caaa7422644389509f" integrity sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw== @@ -1060,6 +1859,13 @@ resolved "https://registry.yarnpkg.com/@types/resize-observer-browser/-/resize-observer-browser-0.1.1.tgz#9b7cdae9cdc8b1a7020ca7588018dac64c770866" integrity sha512-5/bJS/uGB5kmpRrrAWXQnmyKlv+4TlPn4f+A2NBa93p+mt6Ht+YcNGkQKf8HMx28a9hox49ZXShtbGqZkk41Sw== +"@types/resolve@0.0.8": + version "0.0.8" + resolved "https://registry.yarnpkg.com/@types/resolve/-/resolve-0.0.8.tgz#f26074d238e02659e323ce1a13d041eee280e194" + integrity sha512-auApPaJf3NPfe18hSoJkp8EbZzer2ISk7o8mCC3M9he/a04+gbMF97NkpD2S8riMGvm4BMRI59/SZQSaLTKpsQ== + dependencies: + "@types/node" "*" + "@types/semver@^5.5.0": version "5.5.0" resolved "https://registry.yarnpkg.com/@types/semver/-/semver-5.5.0.tgz#146c2a29ee7d3bae4bf2fcb274636e264c813c45" @@ -1248,6 +2054,11 @@ acorn-walk@^7.0.0, acorn-walk@^7.1.1: resolved "https://registry.yarnpkg.com/acorn-walk/-/acorn-walk-7.2.0.tgz#0de889a601203909b0fbe07b8938dc21d2e967bc" integrity sha512-OPdCF6GsMIP+Az+aWfAAOEt2/+iVDKE7oy6lJ098aoe59oAmK76qV6Gw60SbZ8jHuG2wH058GF4pLFbYamYrVA== +acorn@^5.7.3: + version "5.7.4" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.4.tgz#3e8d8a9947d0599a1796d10225d7432f4a4acf5e" + integrity sha512-1D++VG7BhrtvQpNbBzovKNc1FLGGEE/oGe7b9xJm/RFHMBeUaUGpluV9RLjZa47YFdPcDAenEYuq9pQPcMdLJg== + acorn@^6.0.1, acorn@^6.0.2: version "6.4.2" resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.4.2.tgz#35866fd710528e92de10cf06016498e47e39e1e6" @@ -1563,6 +2374,13 @@ babel-jest@^27.0.2: graceful-fs "^4.2.4" slash "^3.0.0" +babel-plugin-dynamic-import-node@^2.3.3: + version "2.3.3" + resolved "https://registry.yarnpkg.com/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.3.tgz#84fda19c976ec5c6defef57f9427b3def66e17a3" + integrity sha512-jZVI+s9Zg3IqA/kdi0i6UDCybUI3aSBLnglhYbSSjKlV7yF1F/5LWv8MakQmvYpnbJDS6fcBL2KzHSxNCMtWSQ== + dependencies: + object.assign "^4.1.0" + babel-plugin-istanbul@^6.0.0: version "6.0.0" resolved "https://registry.yarnpkg.com/babel-plugin-istanbul/-/babel-plugin-istanbul-6.0.0.tgz#e159ccdc9af95e0b570c75b4573b7c34d671d765" @@ -1584,6 +2402,30 @@ babel-plugin-jest-hoist@^27.0.1: "@types/babel__core" "^7.0.0" "@types/babel__traverse" "^7.0.6" +babel-plugin-polyfill-corejs2@^0.2.2: + version "0.2.2" + resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-corejs2/-/babel-plugin-polyfill-corejs2-0.2.2.tgz#e9124785e6fd94f94b618a7954e5693053bf5327" + integrity sha512-kISrENsJ0z5dNPq5eRvcctITNHYXWOA4DUZRFYCz3jYCcvTb/A546LIddmoGNMVYg2U38OyFeNosQwI9ENTqIQ== + dependencies: + "@babel/compat-data" "^7.13.11" + "@babel/helper-define-polyfill-provider" "^0.2.2" + semver "^6.1.1" + +babel-plugin-polyfill-corejs3@^0.2.2: + version "0.2.3" + resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.2.3.tgz#72add68cf08a8bf139ba6e6dfc0b1d504098e57b" + integrity sha512-rCOFzEIJpJEAU14XCcV/erIf/wZQMmMT5l5vXOpL5uoznyOGfDIjPj6FVytMvtzaKSTSVKouOCTPJ5OMUZH30g== + dependencies: + "@babel/helper-define-polyfill-provider" "^0.2.2" + core-js-compat "^3.14.0" + +babel-plugin-polyfill-regenerator@^0.2.2: + version "0.2.2" + resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.2.2.tgz#b310c8d642acada348c1fa3b3e6ce0e851bee077" + integrity sha512-Goy5ghsc21HgPDFtzRkSirpZVW35meGoTmTOb2bxqdl60ghub4xOidgNTHaZfQ2FaxQsKmwvXtOAkcIS4SMBWg== + dependencies: + "@babel/helper-define-polyfill-provider" "^0.2.2" + babel-preset-current-node-syntax@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.0.1.tgz#b4399239b89b2a011f9ddbe3e4f401fc40cff73b" @@ -1610,6 +2452,11 @@ babel-preset-jest@^27.0.1: babel-plugin-jest-hoist "^27.0.1" babel-preset-current-node-syntax "^1.0.0" +babelify@^10.0.0: + version "10.0.0" + resolved "https://registry.yarnpkg.com/babelify/-/babelify-10.0.0.tgz#fe73b1a22583f06680d8d072e25a1e0d1d1d7fb5" + integrity sha512-X40FaxyH7t3X+JFAKvb1H9wooWKLRCi8pg3m8poqtdZaIng+bjzp9RvKQCvRjF9isHiPkXspbbXT/zwXLtwgwg== + balanced-match@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" @@ -1932,6 +2779,11 @@ buffer-equal@0.0.1: resolved "https://registry.yarnpkg.com/buffer-equal/-/buffer-equal-0.0.1.tgz#91bc74b11ea405bc916bc6aa908faafa5b4aac4b" integrity sha1-kbx0sR6kBbyRa8aqkI+q+ltKrEs= +buffer-es6@^4.9.3: + version "4.9.3" + resolved "https://registry.yarnpkg.com/buffer-es6/-/buffer-es6-4.9.3.tgz#f26347b82df76fd37e18bcb5288c4970cfd5c404" + integrity sha1-8mNHuC33b9N+GLy1KIxJcM/VxAQ= + buffer-fill@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/buffer-fill/-/buffer-fill-1.0.0.tgz#f8f78b76789888ef39f205cd637f68e702122b2c" @@ -1963,6 +2815,11 @@ buffer@^5.2.1, buffer@^5.5.0: base64-js "^1.3.1" ieee754 "^1.1.13" +builtin-modules@^3.1.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/builtin-modules/-/builtin-modules-3.2.0.tgz#45d5db99e7ee5e6bc4f362e008bf917ab5049887" + integrity sha512-lGzLKcioL90C7wMczpkY0n/oART3MbBa8R9OFGE1rJxoVI86u4WAGfEk8Wjv10eKSyTHVGkSo3bvBylCEtk7LA== + builtin-status-codes@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/builtin-status-codes/-/builtin-status-codes-3.0.0.tgz#85982878e21b98e1c66425e03d0174788f569ee8" @@ -2600,6 +3457,14 @@ copy-descriptor@^0.1.0: resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= +core-js-compat@^3.14.0, core-js-compat@^3.15.0: + version "3.15.2" + resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.15.2.tgz#47272fbb479880de14b4e6081f71f3492f5bd3cb" + integrity sha512-Wp+BJVvwopjI+A1EFqm2dwUmWYXrvucmtIB2LgXn/Rb+gWPKYxtmb4GKHGKG/KGF1eK9jfjzT38DITbTOCX/SQ== + dependencies: + browserslist "^4.16.6" + semver "7.0.0" + core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" @@ -3407,6 +4272,26 @@ estree-is-function@^1.0.0: resolved "https://registry.yarnpkg.com/estree-is-function/-/estree-is-function-1.0.0.tgz#c0adc29806d7f18a74db7df0f3b2666702e37ad2" integrity sha512-nSCWn1jkSq2QAtkaVLJZY2ezwcFO161HVc174zL1KPW3RJ+O6C3eJb8Nx7OXzvhoEv+nLgSR1g71oWUHUDTrJA== +estree-walker@^0.5.2: + version "0.5.2" + resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-0.5.2.tgz#d3850be7529c9580d815600b53126515e146dd39" + integrity sha512-XpCnW/AE10ws/kDAs37cngSkvgIR8aN3G0MS85m7dUpuK2EREo9VJ00uvw6Dg/hXEpfsE1I1TvJOJr+Z+TL+ig== + +estree-walker@^0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-0.6.1.tgz#53049143f40c6eb918b23671d1fe3219f3a1b362" + integrity sha512-SqmZANLWS0mnatqbSfRP5g8OXZC12Fgg1IwNtLsyHDzJizORW4khDfjPqJZsemPWBB2uqykUah5YpQ6epsqC/w== + +estree-walker@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-1.0.1.tgz#31bc5d612c96b704106b477e6dd5d8aa138cb700" + integrity sha512-1fMXF3YP4pZZVozF8j/ZLfvnR8NSIljt56UhbZ5PeeDmmGHpgpdwQt7ITlGvYaQukCvuBRMLEiKiYC+oeIg4cg== + +estree-walker@^2.0.1: + version "2.0.2" + resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-2.0.2.tgz#52f010178c2a4c117a7757cfe942adb7d2da4cac" + integrity sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w== + esutils@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz#0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b" @@ -3796,7 +4681,7 @@ fs.realpath@^1.0.0: resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= -fsevents@^2.3.2: +fsevents@^2.3.2, fsevents@~2.3.2: version "2.3.2" resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.2.tgz#8a526f78b8fdf4623b709e0b975c52c24c02fd1a" integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA== @@ -4620,6 +5505,11 @@ is-interactive@^1.0.0: resolved "https://registry.yarnpkg.com/is-interactive/-/is-interactive-1.0.0.tgz#cea6e6ae5c870a7b0a0004070b7b587e0252912e" integrity sha512-2HvIEKRoqS62guEC+qBjpvRubdX910WCMuJTZ+I9yvqKU2/12eSL549HMwtabb4oupdj2sMP50k+XJfB/8JE6w== +is-module@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-module/-/is-module-1.0.0.tgz#3258fb69f78c14d5b815d664336b4cffb6441591" + integrity sha1-Mlj7afeMFNW4FdZkM2tM/7ZEFZE= + is-negative-zero@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/is-negative-zero/-/is-negative-zero-2.0.1.tgz#3de746c18dda2319241a53675908d8f766f11c24" @@ -4691,6 +5581,13 @@ is-potential-custom-element-name@^1.0.1: resolved "https://registry.yarnpkg.com/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz#171ed6f19e3ac554394edf78caa05784a45bebb5" integrity sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ== +is-reference@^1.1.2: + version "1.2.1" + resolved "https://registry.yarnpkg.com/is-reference/-/is-reference-1.2.1.tgz#8b2dac0b371f4bc994fdeaba9eb542d03002d0b7" + integrity sha512-U82MsXXiFIrjCK4otLT+o2NA2Cd2g5MLoOVXUZjIOhLurrRxpEXzI8O0KZHr3IjLvlAH1kTPYSuqer5T9ZVBKQ== + dependencies: + "@types/estree" "*" + is-regex@^1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.1.2.tgz#81c8ebde4db142f2cf1c53fc86d6a45788266251" @@ -5368,6 +6265,11 @@ jsesc@^2.5.1: resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== +jsesc@~0.5.0: + version "0.5.0" + resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-0.5.0.tgz#e7dee66e35d6fc16f710fe91d5cf69f70f08911d" + integrity sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0= + json-buffer@3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/json-buffer/-/json-buffer-3.0.0.tgz#5b1f397afc75d677bde8bcfc0e47e1f9a3d9a898" @@ -5619,6 +6521,11 @@ lodash.clonedeep@^4.5.0: resolved "https://registry.yarnpkg.com/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz#e23f3f9c4f8fbdde872529c1071857a086e5ccef" integrity sha1-4j8/nE+Pvd6HJSnBBxhXoIblzO8= +lodash.debounce@^4.0.8: + version "4.0.8" + resolved "https://registry.yarnpkg.com/lodash.debounce/-/lodash.debounce-4.0.8.tgz#82d79bff30a67c4005ffd5e2515300ad9ca4d7af" + integrity sha1-gteb/zCmfEAF/9XiUVMArZyk168= + lodash.defaults@^4.2.0: version "4.2.0" resolved "https://registry.yarnpkg.com/lodash.defaults/-/lodash.defaults-4.2.0.tgz#d09178716ffea4dde9e5fb7b37f6f0802274580c" @@ -5748,6 +6655,20 @@ magic-string@0.25.1: dependencies: sourcemap-codec "^1.4.1" +magic-string@^0.22.5: + version "0.22.5" + resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.22.5.tgz#8e9cf5afddf44385c1da5bc2a6a0dbd10b03657e" + integrity sha512-oreip9rJZkzvA8Qzk9HFs8fZGF/u7H/gtrE8EN6RjKJ9kh2HlC+yQ2QezifqTZfGyiuAV0dRv5a+y/8gBb1m9w== + dependencies: + vlq "^0.2.2" + +magic-string@^0.25.2, magic-string@^0.25.3, magic-string@^0.25.7: + version "0.25.7" + resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.25.7.tgz#3f497d6fd34c669c6798dcb821f2ef31f5445051" + integrity sha512-4CrMT5DOHTDk4HYDlzmwu4FVCcIYI8gauveasrdCu2IKIFOJ3f0v/8MDGJCDL9oD2ppz/Av1b0Nj345H9M+XIA== + dependencies: + sourcemap-codec "^1.4.4" + make-dir@^1.0.0: version "1.3.0" resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-1.3.0.tgz#79c1033b80515bd6d24ec9933e860ca75ee27f0c" @@ -6195,7 +7116,7 @@ object-visit@^1.0.0: dependencies: isobject "^3.0.0" -object.assign@^4.1.2: +object.assign@^4.1.0, object.assign@^4.1.2: version "4.1.2" resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.2.tgz#0ed54a342eceb37b38ff76eb831a0e788cb63940" integrity sha512-ixT2L5THXsApyiUPYKmW+2EHpXXe5Ii3M+f4e+aJFAHao5amFRW6J0OO6c/LU8Be47utCx2GL89hxGB6XSmKuQ== @@ -6572,6 +7493,11 @@ picomatch@^2.0.4, picomatch@^2.0.5, picomatch@^2.2.1: resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.2.2.tgz#21f333e9b6b8eaff02468f5146ea406d345f4dad" integrity sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg== +picomatch@^2.2.2: + version "2.3.0" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.0.tgz#f1f061de8f6a4bf022892e2d128234fb98302972" + integrity sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw== + picomatch@^2.2.3: version "2.2.3" resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.2.3.tgz#465547f359ccc206d3c48e46a1bcb89bf7ee619d" @@ -6673,6 +7599,11 @@ pretty-json-stringify@^0.0.2: resolved "https://registry.yarnpkg.com/pretty-json-stringify/-/pretty-json-stringify-0.0.2.tgz#dc0f1dbeab6bc1ab15f40d4cce4f38b75b17a334" integrity sha1-3A8dvqtrwasV9A1Mzk84t1sXozQ= +process-es6@^0.11.6: + version "0.11.6" + resolved "https://registry.yarnpkg.com/process-es6/-/process-es6-0.11.6.tgz#c6bb389f9a951f82bd4eb169600105bd2ff9c778" + integrity sha1-xrs4n5qVH4K9TrFpYAEFvS/5x3g= + process-nextick-args@~2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" @@ -6941,6 +7872,30 @@ redent@^1.0.0: indent-string "^2.1.0" strip-indent "^1.0.1" +regenerate-unicode-properties@^8.2.0: + version "8.2.0" + resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-8.2.0.tgz#e5de7111d655e7ba60c057dbe9ff37c87e65cdec" + integrity sha512-F9DjY1vKLo/tPePDycuH3dn9H1OTPIkVD9Kz4LODu+F2C75mgjAJ7x/gwy6ZcSNRAAkhNlJSOHRe8k3p+K9WhA== + dependencies: + regenerate "^1.4.0" + +regenerate@^1.4.0: + version "1.4.2" + resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.4.2.tgz#b9346d8827e8f5a32f7ba29637d398b69014848a" + integrity sha512-zrceR/XhGYU/d/opr2EKO7aRHUeiBI8qjtfHqADTwZd6Szfy16la6kqD0MIUs5z5hx6AaKa+PixpPrR289+I0A== + +regenerator-runtime@^0.13.4: + version "0.13.7" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.7.tgz#cac2dacc8a1ea675feaabaeb8ae833898ae46f55" + integrity sha512-a54FxoJDIr27pgf7IgeQGxmqUNYrcV338lf/6gH456HZ/PhX+5BcwHXG9ajESmwe6WRO0tAzRUrRmNONWgkrew== + +regenerator-transform@^0.14.2: + version "0.14.5" + resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.14.5.tgz#c98da154683671c9c4dcb16ece736517e1b7feb4" + integrity sha512-eOf6vka5IO151Jfsw2NO9WpGX58W6wWmefK3I1zEGr0lOD0u8rwPaNqQL1aRxUaxLeKO3ArNh3VYg1KbaD+FFw== + dependencies: + "@babel/runtime" "^7.8.4" + regex-not@^1.0.0, regex-not@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/regex-not/-/regex-not-1.0.2.tgz#1f4ece27e00b0b65e0247a6810e6a85d83a5752c" @@ -6954,6 +7909,18 @@ regexpp@^3.1.0: resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-3.1.0.tgz#206d0ad0a5648cffbdb8ae46438f3dc51c9f78e2" integrity sha512-ZOIzd8yVsQQA7j8GCSlPGXwg5PfmA1mrq0JP4nGhh54LaKN3xdai/vHUDu74pKwV8OxseMS65u2NImosQcSD0Q== +regexpu-core@^4.7.1: + version "4.7.1" + resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-4.7.1.tgz#2dea5a9a07233298fbf0db91fa9abc4c6e0f8ad6" + integrity sha512-ywH2VUraA44DZQuRKzARmw6S66mr48pQVva4LBeRhcOltJ6hExvWly5ZjFLYo67xbIxb6W1q4bAGtgfEl20zfQ== + dependencies: + regenerate "^1.4.0" + regenerate-unicode-properties "^8.2.0" + regjsgen "^0.5.1" + regjsparser "^0.6.4" + unicode-match-property-ecmascript "^1.0.4" + unicode-match-property-value-ecmascript "^1.2.0" + registry-auth-token@^4.0.0: version "4.2.0" resolved "https://registry.yarnpkg.com/registry-auth-token/-/registry-auth-token-4.2.0.tgz#1d37dffda72bbecd0f581e4715540213a65eb7da" @@ -6968,6 +7935,18 @@ registry-url@^5.0.0: dependencies: rc "^1.2.8" +regjsgen@^0.5.1: + version "0.5.2" + resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.5.2.tgz#92ff295fb1deecbf6ecdab2543d207e91aa33733" + integrity sha512-OFFT3MfrH90xIW8OOSyUrk6QHD5E9JOTeGodiJeBS3J6IwlgzJMNE/1bZklWz5oTg+9dCMyEetclvCVXOPoN3A== + +regjsparser@^0.6.4: + version "0.6.9" + resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.6.9.tgz#b489eef7c9a2ce43727627011429cf833a7183e6" + integrity sha512-ZqbNRz1SNjLAiYuwY0zoXW8Ne675IX5q+YHioAGbCw4X96Mjl2+dcX9B2ciaeyYjViDAfvIjFpQjJgLttTEERQ== + dependencies: + jsesc "~0.5.0" + remove-trailing-separator@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" @@ -7086,7 +8065,7 @@ resolve-url@^0.2.1: resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" integrity sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo= -resolve@^1.1.4, resolve@^1.1.5, resolve@^1.1.6, resolve@^1.10.0, resolve@^1.17.0, resolve@^1.20.0, resolve@^1.4.0: +resolve@^1.1.4, resolve@^1.1.5, resolve@^1.1.6, resolve@^1.10.0, resolve@^1.11.0, resolve@^1.11.1, resolve@^1.14.2, resolve@^1.17.0, resolve@^1.20.0, resolve@^1.4.0: version "1.20.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.20.0.tgz#629a013fb3f70755d6f0b7935cc1c2c5378b1975" integrity sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A== @@ -7146,6 +8125,80 @@ robots-parser@^2.0.1: resolved "https://registry.npmjs.org/robots-parser/-/robots-parser-2.1.0.tgz#d16b78ce34e861ab6afbbf0aac65974dbe01566e" integrity sha512-k07MeDS1Tl1zjoYs5bHfUbgQ0MfaeTOepDcjZFxdYXd84p6IeLDQyUwlMk2AZ9c2yExA30I3ayWhmqz9tg0DzQ== +rollup-plugin-commonjs@^10.1.0: + version "10.1.0" + resolved "https://registry.yarnpkg.com/rollup-plugin-commonjs/-/rollup-plugin-commonjs-10.1.0.tgz#417af3b54503878e084d127adf4d1caf8beb86fb" + integrity sha512-jlXbjZSQg8EIeAAvepNwhJj++qJWNJw1Cl0YnOqKtP5Djx+fFGkp3WRh+W0ASCaFG5w1jhmzDxgu3SJuVxPF4Q== + dependencies: + estree-walker "^0.6.1" + is-reference "^1.1.2" + magic-string "^0.25.2" + resolve "^1.11.0" + rollup-pluginutils "^2.8.1" + +rollup-plugin-ignore@^1.0.9: + version "1.0.9" + resolved "https://registry.yarnpkg.com/rollup-plugin-ignore/-/rollup-plugin-ignore-1.0.9.tgz#62a692d387d543395ad2fbcc443c9b3549582844" + integrity sha512-+Q2jmD4gbO3ByFuljkDEfpEcYvll7J5+ZadUuk/Pu35x2KGrbHxKtt3+s+dPIgXX1mG7zCxG4s/NdRqztR5Ruw== + +rollup-plugin-inject@^3.0.0: + version "3.0.2" + resolved "https://registry.yarnpkg.com/rollup-plugin-inject/-/rollup-plugin-inject-3.0.2.tgz#e4233855bfba6c0c12a312fd6649dff9a13ee9f4" + integrity sha512-ptg9PQwzs3orn4jkgXJ74bfs5vYz1NCZlSQMBUA0wKcGp5i5pA1AO3fOUEte8enhGUC+iapTCzEWw2jEFFUO/w== + dependencies: + estree-walker "^0.6.1" + magic-string "^0.25.3" + rollup-pluginutils "^2.8.1" + +rollup-plugin-node-globals@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/rollup-plugin-node-globals/-/rollup-plugin-node-globals-1.4.0.tgz#5e1f24a9bb97c0ef51249f625e16c7e61b7c020b" + integrity sha512-xRkB+W/m1KLIzPUmG0ofvR+CPNcvuCuNdjVBVS7ALKSxr3EDhnzNceGkGi1m8MToSli13AzKFYH4ie9w3I5L3g== + dependencies: + acorn "^5.7.3" + buffer-es6 "^4.9.3" + estree-walker "^0.5.2" + magic-string "^0.22.5" + process-es6 "^0.11.6" + rollup-pluginutils "^2.3.1" + +rollup-plugin-node-polyfills@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/rollup-plugin-node-polyfills/-/rollup-plugin-node-polyfills-0.2.1.tgz#53092a2744837164d5b8a28812ba5f3ff61109fd" + integrity sha512-4kCrKPTJ6sK4/gLL/U5QzVT8cxJcofO0OU74tnB19F40cmuAKSzH5/siithxlofFEjwvw1YAhPmbvGNA6jEroA== + dependencies: + rollup-plugin-inject "^3.0.0" + +rollup-plugin-node-resolve@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/rollup-plugin-node-resolve/-/rollup-plugin-node-resolve-5.2.0.tgz#730f93d10ed202473b1fb54a5997a7db8c6d8523" + integrity sha512-jUlyaDXts7TW2CqQ4GaO5VJ4PwwaV8VUGA7+km3n6k6xtOEacf61u0VXwN80phY/evMcaS+9eIeJ9MOyDxt5Zw== + dependencies: + "@types/resolve" "0.0.8" + builtin-modules "^3.1.0" + is-module "^1.0.0" + resolve "^1.11.1" + rollup-pluginutils "^2.8.1" + +rollup-plugin-shim@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/rollup-plugin-shim/-/rollup-plugin-shim-1.0.0.tgz#b00f5cb44cdae81358c5342fe82fa71a1602b56b" + integrity sha512-rZqFD43y4U9nSqVq3iyWBiDwmBQJY8Txi04yI9jTKD3xcl7CbFjh1qRpQshUB3sONLubDzm7vJiwB+1MEGv67w== + +rollup-pluginutils@^2.3.1, rollup-pluginutils@^2.8.1: + version "2.8.2" + resolved "https://registry.yarnpkg.com/rollup-pluginutils/-/rollup-pluginutils-2.8.2.tgz#72f2af0748b592364dbd3389e600e5a9444a351e" + integrity sha512-EEp9NhnUkwY8aif6bxgovPHMoMoNr2FulJziTndpt5H9RdwC47GSGuII9XxpSdzVGM0GWrNPHV6ie1LTNJPaLQ== + dependencies: + estree-walker "^0.6.1" + +rollup@^2.52.6: + version "2.52.6" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.52.6.tgz#7c7546d170dead0e7db0b6c709f7f34398498a8e" + integrity sha512-H+Xudmwf8KO+xji8njQNoIQRp8l+iQge/NdUR20JngTxVYdEEnlpkMvQ71YGLl3+xZcPecmdj4q2lrClKaPdRA== + optionalDependencies: + fsevents "~2.3.2" + run-async@^2.4.0: version "2.4.1" resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.4.1.tgz#8440eccf99ea3e70bd409d49aab88e10c189a455" @@ -7223,7 +8276,12 @@ semver-diff@^3.1.1: resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== -semver@^6.0.0, semver@^6.2.0, semver@^6.3.0: +semver@7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.0.0.tgz#5f3ca35761e47e05b206c6daff2cf814f0316b8e" + integrity sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A== + +semver@^6.0.0, semver@^6.1.1, semver@^6.1.2, semver@^6.2.0, semver@^6.3.0: version "6.3.0" resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== @@ -7424,7 +8482,7 @@ source-map@^0.7.3, source-map@~0.7.2: resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.3.tgz#5302f8169031735226544092e64981f751750383" integrity sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ== -sourcemap-codec@^1.4.1: +sourcemap-codec@^1.4.1, sourcemap-codec@^1.4.4: version "1.4.8" resolved "https://registry.yarnpkg.com/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz#ea804bd94857402e6992d05a38ef1ae35a9ab4c4" integrity sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA== @@ -8172,6 +9230,29 @@ underscore@^1.9.1: resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.13.1.tgz#0c1c6bd2df54b6b69f2314066d65b6cde6fcf9d1" integrity sha512-hzSoAVtJF+3ZtiFX0VgfFPHEDRm7Y/QPjGyNo4TVdnDTdft3tr8hEkD25a1jC+TjTuE7tkHGKkhwCgs9dgBB2g== +unicode-canonical-property-names-ecmascript@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz#2619800c4c825800efdd8343af7dd9933cbe2818" + integrity sha512-jDrNnXWHd4oHiTZnx/ZG7gtUTVp+gCcTTKr8L0HjlwphROEW3+Him+IpvC+xcJEFegapiMZyZe02CyuOnRmbnQ== + +unicode-match-property-ecmascript@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-1.0.4.tgz#8ed2a32569961bce9227d09cd3ffbb8fed5f020c" + integrity sha512-L4Qoh15vTfntsn4P1zqnHulG0LdXgjSO035fEpdtp6YxXhMT51Q6vgM5lYdG/5X3MjS+k/Y9Xw4SFCY9IkR0rg== + dependencies: + unicode-canonical-property-names-ecmascript "^1.0.4" + unicode-property-aliases-ecmascript "^1.0.4" + +unicode-match-property-value-ecmascript@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.2.0.tgz#0d91f600eeeb3096aa962b1d6fc88876e64ea531" + integrity sha512-wjuQHGQVofmSJv1uVISKLE5zO2rNGzM/KCYZch/QQvez7C1hUhBIuZ701fYXExuufJFMPhv2SyL8CyoIfMLbIQ== + +unicode-property-aliases-ecmascript@^1.0.4: + version "1.1.0" + resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.1.0.tgz#dd57a99f6207bedff4628abefb94c50db941c8f4" + integrity sha512-PqSoPh/pWetQ2phoj5RLiaqIk4kCNwoV3CI+LfGmWLKI3rE3kl1h59XpX2BjgDrmbxD9ARtQobPGU1SguCYuQg== + union-value@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/union-value/-/union-value-1.0.1.tgz#0b6fe7b835aecda61c6ea4d4f02c14221e109847" @@ -8330,6 +9411,11 @@ verror@1.3.6: dependencies: extsprintf "1.0.2" +vlq@^0.2.2: + version "0.2.3" + resolved "https://registry.yarnpkg.com/vlq/-/vlq-0.2.3.tgz#8f3e4328cf63b1540c0d67e1b2778386f8975b26" + integrity sha512-DRibZL6DsNhIgYQ+wNdWDL2SL3bKPlVrRiBqV5yuMm++op8W4kGFtaQfCs4KEJn0wBZcHVHJ3eoywX8983k1ow== + vm-browserify@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/vm-browserify/-/vm-browserify-1.1.0.tgz#bd76d6a23323e2ca8ffa12028dc04559c75f9019" From f9ddfa401fb84285ff8081275a7ac7804e14a06f Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 2 Jul 2021 21:58:31 -0700 Subject: [PATCH 02/36] wip --- build/build-bundle.js | 135 +- build/build-dt-report-resources.js | 4 +- build/rollup-brfs.js | 54 + build/rollup-postprocess.js | 40 + clients/devtools-entry.js | 17 +- clients/devtools-report-assets.js | 2 +- clients/package.json | 1 - .../config/{tmpdir => }/config-helpers.js | 39 +- lighthouse-core/config/config.js | 5 +- lighthouse-core/fraggle-rock/config/config.js | 2 +- .../fraggle-rock/gather/base-gatherer.js | 7 +- .../dobetterweb/response-compression.js | 1 + lighthouse-core/lib/asset-saver.js | 8 +- lighthouse-core/lib/i18n/i18n.js | 2 +- lighthouse-core/lib/lh-env.js | 2 + lighthouse-core/lib/tappable-rects.js | 23 +- lighthouse-core/lib/url-shim.js | 2 +- lighthouse-logger/index.js | 11 +- package.json | 12 +- report/assets/standalone-template.html | 1 + report/clients/standalone.js | 54 +- .../renderer/element-screenshot-renderer.js | 4 +- yarn.lock | 1286 +++++------------ 23 files changed, 666 insertions(+), 1046 deletions(-) create mode 100644 build/rollup-brfs.js create mode 100644 build/rollup-postprocess.js delete mode 100644 clients/package.json rename lighthouse-core/config/{tmpdir => }/config-helpers.js (95%) diff --git a/build/build-bundle.js b/build/build-bundle.js index b5cf17a057f6..f69f6f7167ca 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -17,9 +17,10 @@ const mkdir = fs.promises.mkdir; const LighthouseRunner = require('../lighthouse-core/runner.js'); const exorcist = require('exorcist'); const browserify = require('browserify'); -const babelify = require('babelify'); const terser = require('terser'); const {minifyFileTransform} = require('./build-utils.js'); +const Runner = require('../lighthouse-core/runner.js'); +const rollupBrfs = require('./rollup-brfs.js'); const {LH_ROOT} = require('../root.js'); const COMMIT_HASH = require('child_process') @@ -65,7 +66,6 @@ async function browserifyFile(entryPath, distPath) { pkg: Object.assign({COMMIT_HASH}, require('../package.json')), file: require.resolve('./banner.txt'), }) - .transform(babelify, {presets: [['@babel/preset-env']]}) // Transform the fs.readFile etc into inline strings. .transform('@wardpeet/brfs', { readFileSyncTransform: minifyFileTransform, @@ -186,33 +186,132 @@ async function minifyScript(filePath) { */ async function build(entryPath, distPath) { const rollup = require('rollup'); - // const {terser} = require('rollup-plugin-terser'); + const {terser} = require('rollup-plugin-terser'); // Only needed b/c getFilenamePrefix loads a commonjs module. const commonjs = // @ts-expect-error types are wrong. /** @type {import('rollup-plugin-commonjs').default} */ (require('rollup-plugin-commonjs')); + // List of paths (absolute / relative to config-helpers.js) to include + // in bundle and make accessible via config-helpers.js `requireWrapper`. + const dynamicModulePaths = [ + ...Runner.getGathererList().map(gatherer => `../gather/gatherers/${gatherer}`), + ...Runner.getAuditList().map(gatherer => `../audits/${gatherer}`), + ]; + + // Include lighthouse-plugin-publisher-ads. + if (isDevtools(entryPath) || isLightrider(entryPath)) { + // TODO: doesn't work yet (circular deps?) + // dynamicModulePaths.push('lighthouse-plugin-publisher-ads'); + // pubAdsAudits.forEach(pubAdAudit => { + // dynamicModulePaths.push(pubAdAudit); + // }); + } + + const bundledMapEntriesCode = dynamicModulePaths.map(modulePath => { + const pathNoExt = modulePath.replace('.js', ''); + return `['${pathNoExt}', require('${modulePath}')]`; + }).join(',\n'); + + const shimsObj = {}; + const modulesToIgnore = [ + 'intl-pluralrules', + 'intl', + 'pako/lib/zlib/inflate.js', + 'raven', + 'source-map', + 'ws', + ]; + + // Don't include the stringified report in DevTools - see devtools-report-assets.js + // Don't include in Lightrider - HTML generation isn't supported, so report assets aren't needed. + if (isDevtools(entryPath) || isLightrider(entryPath)) { + modulesToIgnore.push(require.resolve('../report/report-assets.js')); + } + + // Don't include locales in DevTools. + if (isDevtools(entryPath)) { + const localeKeys = Object.keys(require('../lighthouse-core/lib/i18n/locales.js')); + const localesShim = {}; + for (const key of localeKeys) localesShim[key] = {}; + shimsObj['./locales.js'] = `export default ${JSON.stringify(localesShim)}`; + } + + for (const modulePath of modulesToIgnore) { + shimsObj[modulePath] = 'export default {}'; + } + + // rollup inject? + const bundle = await rollup.rollup({ input: entryPath, + context: 'globalThis', plugins: [ + require('@rollup/plugin-json')(), + require('rollup-plugin-replace')({ + delimiters: ['', ''], + values: { + 'const bundledModules = new Map();': + `const bundledModules = new Map([\n${bundledMapEntriesCode},\n]);`, + '__dirname': (id) => `'${path.relative(LH_ROOT, path.dirname(id))}'`, + '__filename': (id) => `'${path.relative(LH_ROOT, id)}'`, + }, + }), require('rollup-plugin-shim')({ - [LH_ROOT + '/root.js']: 'export default {LH_ROOT: "."}', - './lighthouse-core/lib/i18n/locales.js': 'export default {}', - 'debug/node': 'export default {}', - 'intl-pluralrules': 'export default {}', - 'intl': 'export default {}', - 'lighthouse-logger': 'export default {}', - 'pako/lib/zlib/inflate.js': 'export default {}', - 'raven': 'export default {}', - 'source-map': 'export default {}', - 'ws': 'export default {}', + ...shimsObj, + + 'debug': `export * from '${require.resolve('debug/src/browser.js')}'`, + // 'lighthouse-logger': 'export default {}', + + // This allows for plugins to import lighthouse. TODO: lol no it doesnt + // [require.resolve('lighthouse')]: 'export {__moduleExports: {Audit: 1}};', + // [require.resolve('debug/node')]: 'export default {}', + // 'intl-pluralrules': 'export default {}', + // 'intl': 'export default {}', + // 'pako/lib/zlib/inflate.js': 'export default {}', + // 'raven': 'export default {}', + // 'source-map': 'export default {}', + // 'ws': 'export default {}', }), - commonjs(), - // require('rollup-plugin-node-globals')(), - // terser(), - require('@rollup/plugin-json')(), - require("rollup-plugin-node-resolve")({preferBuiltins: true}), + // Currently must run before commonjs (brfs does not support import). + rollupBrfs({ + readFileSyncTransform: minifyFileTransform, + global: true, + parserOpts: {ecmaVersion: 12, sourceType: 'module'}, + }), + + commonjs({ + // https://github.com/rollup/plugins/issues/922 + ignoreGlobal: true, + }), + + require('rollup-plugin-node-resolve')({preferBuiltins: true}), + require('rollup-plugin-node-builtins')(), require('rollup-plugin-node-polyfills')(), + // Rollup sees the usages of these functions in page functions (ex: see AnchorElements) + // and treats them as globals. Because the names are "taken" by the global, Rollup renames + // the actual functions. The page functions expect a certain name, and so here we undo what + // Rollup did. + require('./rollup-postprocess.js')([ + [/getElementsInDocument\$1/, 'getElementsInDocument'], + [/getNodeDetails\$1/, 'getNodeDetails'], + [/getRectCenterPoint\$1/, 'getRectCenterPoint'], + ]), + terser({ + ecma: 2019, + output: { + comments: /^!/, + max_line_len: 1000, + }, + // The config relies on class names for gatherers. + keep_classnames: true, + // Runtime.evaluate errors if function names are elided. + keep_fnames: true, + // sourceMap: DEBUG && { + // content: JSON.parse(fs.readFileSync(`${filePath}.map`, 'utf-8')), + // url: path.basename(`${filePath}.map`), + // }, + }), ], }); diff --git a/build/build-dt-report-resources.js b/build/build-dt-report-resources.js index 6f3a97ddf339..9f1e9d853119 100644 --- a/build/build-dt-report-resources.js +++ b/build/build-dt-report-resources.js @@ -38,8 +38,8 @@ writeFile('report-generator.d.ts', 'export {}'); const pathToReportAssets = require.resolve('../clients/devtools-report-assets.js'); browserify(generatorFilename, {standalone: 'Lighthouse.ReportGenerator'}) - // Shims './html/html-report-assets.js' to resolve to devtools-report-assets.js - .require(pathToReportAssets, {expose: './html/html-report-assets.js'}) + // Shims './report/report-assets.js' to resolve to devtools-report-assets.js + .require(pathToReportAssets, {expose: './report-assets.js'}) .bundle((err, src) => { if (err) throw err; fs.writeFileSync(bundleOutFile, src.toString()); diff --git a/build/rollup-brfs.js b/build/rollup-brfs.js new file mode 100644 index 000000000000..9aa96cba33a3 --- /dev/null +++ b/build/rollup-brfs.js @@ -0,0 +1,54 @@ +/** + * @license Copyright 2021 The Lighthouse Authors. All Rights Reserved. + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. + */ +'use strict'; + + +const {Plugin} = require('rollup'); +const path = require('path'); +const {Readable} = require('stream'); + +const brfs = require('@wardpeet/brfs'); +const EXTENSIONS = ['.js', '.jsx', '.ts', '.tsx']; + +const rollupBrfs = function rollUpBrfs(options = {}) { + return { + name: 'brfs', + transform(code, id) { + const ext = path.extname(id); + if (!EXTENSIONS.includes(ext)) { + return null; + } + return new Promise((resolve, reject) => { + let output = ''; + const src = new Readable(); + // if (id.endsWith('stacks.js')) { + // debugger; + // code = code.replace(/commonjsHelpers\.commonjsRequire\.resolve\(/g, 'require.resolve('); + // code = code.replace(/import fs from '\u0000fs\?commonjs-proxy';/g, "import fs from 'fs';"); + // } + src.push(code); + src.push(null); + const stream = src.pipe(brfs(id, options)); + stream.on('data', function(data) { + output += data.toString(); + }); + stream.on('end', function() { + // if (id.endsWith('stacks.js')) { + // console.log({id, code}); + // } + resolve({ + code: output, + map: {mappings: ''}, + }); + }); + stream.on('error', function(error) { + reject(error); + }); + }); + }, + }; +}; +module.exports = rollupBrfs; diff --git a/build/rollup-postprocess.js b/build/rollup-postprocess.js new file mode 100644 index 000000000000..cf4a061406a6 --- /dev/null +++ b/build/rollup-postprocess.js @@ -0,0 +1,40 @@ +const MagicString = require('magic-string'); + +let currentToken; +const replacer = (str, index) => currentToken[index]; + +module.exports = function postprocess(allReplacements) { + return { + name: 'postprocess', + renderChunk(code, {sourceMap, format}) { + const str = new MagicString(code); + const replacements = typeof allReplacements === 'function' ? allReplacements({code, sourceMap, format}) : allReplacements; + + for (let i = 0; i < replacements.length; i++) { + let [find, replace = ''] = replacements[i]; + if (typeof find === 'string') find = new RegExp(find); + if (!find.global) { + find = new RegExp(find.source, 'g' + String(find).split('/').pop()); + } + + let token; + while (token = find.exec(code)) { + let value; + if (typeof replace === 'function') { + value = replace.apply(null, token); + if (value == null) value = ''; + } else { + currentToken = token; + value = replace.replace(/\$(\d+)/, replacer); + } + str.overwrite(token.index, token.index + token[0].length, value); + } + } + + return { + code: str.toString(), + map: sourceMap === false ? null : str.generateMap({hires: true}), + }; + }, + }; +}; diff --git a/clients/devtools-entry.js b/clients/devtools-entry.js index 647627c5dca8..2dc4ef8093e1 100644 --- a/clients/devtools-entry.js +++ b/clients/devtools-entry.js @@ -5,13 +5,11 @@ */ 'use strict'; -import * as lighthouse from '../lighthouse-core/index.js'; -import * as RawProtocol from '../lighthouse-core/gather/connections/raw.js'; -import * as log from 'lighthouse-logger'; -import {registerLocaleData, lookupLocale} from '../lighthouse-core/lib/i18n/i18n.js'; -import * as constants from '../lighthouse-core/config/constants.js'; - -import * as configHelpers from '../lighthouse-core/config/tmpdir/config-helpers.js'; +const lighthouse = require('../lighthouse-core/index.js'); +const RawProtocol = require('../lighthouse-core/gather/connections/raw.js'); +const log = require('../lighthouse-logger/index.js'); +const {registerLocaleData, lookupLocale} = require('../lighthouse-core/lib/i18n/i18n.js'); +const constants = require('../lighthouse-core/config/constants.js'); /** @typedef {import('../lighthouse-core/gather/connections/connection.js')} Connection */ @@ -43,7 +41,7 @@ function createConfig(categoryIDs, device) { return { extends: 'lighthouse:default', - plugins: ['lighthouse-plugin-publisher-ads'], + // plugins: ['lighthouse-plugin-publisher-ads'], settings, }; } @@ -89,6 +87,3 @@ if (typeof self !== 'undefined') { // @ts-expect-error self.lookupLocale = lookupLocale; } - - -console.log(configHelpers.resolveModulePath('./audits/viewport.js')); diff --git a/clients/devtools-report-assets.js b/clients/devtools-report-assets.js index aaec19e5fe71..d980ed47a4d1 100644 --- a/clients/devtools-report-assets.js +++ b/clients/devtools-report-assets.js @@ -20,7 +20,7 @@ const cachedResources = globalThis.EXPORTED_CACHED_RESOURCES_ONLY_FOR_LIGHTHOUSE // resources after this module is resolved. These properties are not // read from immediately, so we can defer reading with getters and everything // is going to be OK. -export default { +module.exports = { get REPORT_CSS() { return cachedResources.get('third_party/lighthouse/report-assets/report.css'); }, diff --git a/clients/package.json b/clients/package.json deleted file mode 100644 index 1632c2c4df68..000000000000 --- a/clients/package.json +++ /dev/null @@ -1 +0,0 @@ -{"type": "module"} \ No newline at end of file diff --git a/lighthouse-core/config/tmpdir/config-helpers.js b/lighthouse-core/config/config-helpers.js similarity index 95% rename from lighthouse-core/config/tmpdir/config-helpers.js rename to lighthouse-core/config/config-helpers.js index 7c461e5fca10..238e7f0c82ad 100644 --- a/lighthouse-core/config/tmpdir/config-helpers.js +++ b/lighthouse-core/config/config-helpers.js @@ -7,13 +7,13 @@ const path = require('path'); const isDeepEqual = require('lodash.isequal'); -const constants = require('../constants.js'); -const Budget = require('../budget.js'); -const Audit = require('../../audits/audit.js'); -const Runner = require('../../runner.js'); -const i18n = require('../../lib/i18n/i18n.js'); +const constants = require('./constants.js'); +const Budget = require('./budget.js'); +const Audit = require('../audits/audit.js'); +const Runner = require('../runner.js'); +const i18n = require('../lib/i18n/i18n.js'); -/** @typedef {typeof import('../../gather/gatherers/gatherer.js')} GathererConstructor */ +/** @typedef {typeof import('../gather/gatherers/gatherer.js')} GathererConstructor */ /** @typedef {InstanceType} Gatherer */ /** @@ -218,6 +218,18 @@ function expandAuditShorthand(audit) { } } +/** @type {Map} */ +const bundledModules = new Map(); + +/** + * Wraps `require` with an entrypoint for bundled dynamic modules. + * See build-bundle.js + * @param {string} requirePath + */ +function requireWrapper(requirePath) { + return bundledModules.get(requirePath) || require(requirePath); +} + /** * @param {string} gathererPath * @param {Array} coreGathererList @@ -233,7 +245,7 @@ function requireGatherer(gathererPath, coreGathererList, configDir) { requirePath = resolveModulePath(gathererPath, configDir, 'gatherer'); } - const GathererClass = /** @type {GathererConstructor} */ (require(requirePath)); + const GathererClass = /** @type {GathererConstructor} */ (requireWrapper(requirePath)); return { instance: new GathererClass(), @@ -243,31 +255,30 @@ function requireGatherer(gathererPath, coreGathererList, configDir) { } /** - * * @param {string} auditPath * @param {Array} coreAuditList * @param {string=} configDir * @return {LH.Config.AuditDefn['implementation']} */ function requireAudit(auditPath, coreAuditList, configDir) { -// See if the audit is a Lighthouse core audit. + // See if the audit is a Lighthouse core audit. const auditPathJs = `${auditPath}.js`; const coreAudit = coreAuditList.find(a => a === auditPathJs); let requirePath = `../audits/${auditPath}`; if (!coreAudit) { - // TODO: refactor and delete `global.isDevtools`. + // TODO: refactor and delete `global.isDevtools`. if (global.isDevtools || global.isLightrider) { - // This is for pubads bundling. + // This is for pubads bundling. requirePath = auditPath; } else { - // Otherwise, attempt to find it elsewhere. This throws if not found. + // Otherwise, attempt to find it elsewhere. This throws if not found. const absolutePath = resolveModulePath(auditPath, configDir, 'audit'); // Use a relative path so bundler can easily expose it. requirePath = path.relative(__dirname, absolutePath); } } - return require(requirePath); + return requireWrapper(requirePath); } /** @@ -328,7 +339,6 @@ function resolveSettings(settingsJson = {}, overrides = undefined) { return settingsWithFlags; } - /** * Turns a GathererJson into a GathererDefn which involves a few main steps: * - Expanding the JSON shorthand the full definition format. @@ -558,6 +568,7 @@ module.exports = { deepCloneConfigJson, mergeOptionsOfItems, mergeConfigFragment, + requireWrapper, resolveSettings, resolveGathererToDefn, resolveAuditsToDefns, diff --git a/lighthouse-core/config/config.js b/lighthouse-core/config/config.js index da1689837991..443fd949c59a 100644 --- a/lighthouse-core/config/config.js +++ b/lighthouse-core/config/config.js @@ -16,13 +16,14 @@ const Runner = require('../runner.js'); const ConfigPlugin = require('./config-plugin.js'); const { mergeConfigFragment, + requireWrapper, resolveSettings, resolveAuditsToDefns, resolveGathererToDefn, resolveModulePath, deepClone, deepCloneConfigJson, -} = require('./tmpdir/config-helpers.js'); +} = require('./config-helpers.js'); /** @typedef {typeof import('../gather/gatherers/gatherer.js')} GathererConstructor */ /** @typedef {InstanceType} Gatherer */ @@ -354,7 +355,7 @@ class Config { const pluginPath = global.isDevtools || global.isLightrider ? pluginName : resolveModulePath(pluginName, configDir, 'plugin'); - const rawPluginJson = require(pluginPath); + const rawPluginJson = requireWrapper(pluginPath); const pluginJson = ConfigPlugin.parsePlugin(rawPluginJson, pluginName); configJSON = Config.extendConfigJSON(configJSON, pluginJson); diff --git a/lighthouse-core/fraggle-rock/config/config.js b/lighthouse-core/fraggle-rock/config/config.js index 154f2ca48b5e..db07e6a28891 100644 --- a/lighthouse-core/fraggle-rock/config/config.js +++ b/lighthouse-core/fraggle-rock/config/config.js @@ -23,7 +23,7 @@ const { resolveSettings, resolveAuditsToDefns, resolveGathererToDefn, -} = require('../../config/tmpdir/config-helpers.js'); +} = require('../../config/config-helpers.js'); const defaultConfigPath = path.join(__dirname, './default-config.js'); /** diff --git a/lighthouse-core/fraggle-rock/gather/base-gatherer.js b/lighthouse-core/fraggle-rock/gather/base-gatherer.js index 901192beb9f9..1a89d41673ac 100644 --- a/lighthouse-core/fraggle-rock/gather/base-gatherer.js +++ b/lighthouse-core/fraggle-rock/gather/base-gatherer.js @@ -63,7 +63,12 @@ class FRGatherer { */ get name() { // @ts-expect-error - assume that class name has been added to LH.GathererArtifacts. - return this.constructor.name; + let name = this.constructor.name; + // Rollup will mangle class names in an known way–just trim until `$`. + if (name.includes('$')) { + name = name.substr(0, name.indexOf('$')); + } + return name; } /** diff --git a/lighthouse-core/gather/gatherers/dobetterweb/response-compression.js b/lighthouse-core/gather/gatherers/dobetterweb/response-compression.js index c2f2be701612..106020e9ea5b 100644 --- a/lighthouse-core/gather/gatherers/dobetterweb/response-compression.js +++ b/lighthouse-core/gather/gatherers/dobetterweb/response-compression.js @@ -10,6 +10,7 @@ */ 'use strict'; +const {Buffer} = require('buffer'); const FRGatherer = require('../../../fraggle-rock/gather/base-gatherer.js'); const URL = require('../../../lib/url-shim.js'); const Sentry = require('../../../lib/sentry.js'); diff --git a/lighthouse-core/lib/asset-saver.js b/lighthouse-core/lib/asset-saver.js index d4aaff2f97c4..dba7885da653 100644 --- a/lighthouse-core/lib/asset-saver.js +++ b/lighthouse-core/lib/asset-saver.js @@ -9,14 +9,12 @@ const fs = require('fs'); const path = require('path'); const log = require('lighthouse-logger'); const stream = require('stream'); -const {promisify} = require('util'); const Simulator = require('./dependency-graph/simulator/simulator.js'); const lanternTraceSaver = require('./lantern-trace-saver.js'); const Metrics = require('./traces/pwmetrics-events.js'); const NetworkAnalysisComputed = require('../computed/network-analysis.js'); const LoadSimulatorComputed = require('../computed/load-simulator.js'); const LHError = require('../lib/lh-error.js'); -const pipeline = promisify(stream.pipeline); const artifactsFilename = 'artifacts.json'; const traceSuffix = '.trace.json'; @@ -249,8 +247,10 @@ async function saveTrace(traceData, traceFilename) { function saveDevtoolsLog(devtoolsLog, devtoolLogFilename) { const logIter = arrayOfObjectsJsonGenerator(devtoolsLog); const writeStream = fs.createWriteStream(devtoolLogFilename); - - return pipeline(stream.Readable.from(logIter), writeStream); + return new Promise((resolve, reject) => { + stream.on('error', reject); + stream.on('done', resolve); + }); } /** diff --git a/lighthouse-core/lib/i18n/i18n.js b/lighthouse-core/lib/i18n/i18n.js index 977d21a09c8c..d9bd82ba950e 100644 --- a/lighthouse-core/lib/i18n/i18n.js +++ b/lighthouse-core/lib/i18n/i18n.js @@ -8,7 +8,7 @@ /** @typedef {import('../../lib/i18n/locales').LhlMessages} LhlMessages */ const path = require('path'); -const MessageFormat = require('intl-messageformat').default; +const MessageFormat = require('intl-messageformat').default || require('intl-messageformat'); const lookupClosestLocale = require('lookup-closest-locale'); const LOCALES = require('./locales.js'); const {isObjectOfUnknownValues, isObjectOrArrayOfUnknownValues} = require('../type-verifiers.js'); diff --git a/lighthouse-core/lib/lh-env.js b/lighthouse-core/lib/lh-env.js index ec0bf6c494d5..fac8fd29ab47 100644 --- a/lighthouse-core/lib/lh-env.js +++ b/lighthouse-core/lib/lh-env.js @@ -5,6 +5,8 @@ */ 'use strict'; +const process = require('process'); + module.exports = { // NODE_ENV is set to test by jest and by smokehouse CLI runner // CI as a catchall for everything we do in GitHub Actions diff --git a/lighthouse-core/lib/tappable-rects.js b/lighthouse-core/lib/tappable-rects.js index 19f96809036e..b20f8bdca6b3 100644 --- a/lighthouse-core/lib/tappable-rects.js +++ b/lighthouse-core/lib/tappable-rects.js @@ -5,14 +5,7 @@ */ 'use strict'; -const { - filterOutRectsContainedByOthers, - filterOutTinyRects, - rectsTouchOrOverlap, - rectContainsPoint, - getBoundingRect, - getRectCenterPoint, -} = require('./rect-helpers.js'); +const RectHelpers = require('./rect-helpers.js'); /** * Merge client rects together and remove small ones. This may result in a larger overall @@ -23,8 +16,8 @@ const { function getTappableRectsFromClientRects(clientRects) { // 1x1px rect shouldn't be reason to treat the rect as something the user should tap on. // Often they're made invisble in some obscure way anyway, and only exist for e.g. accessibiliity. - clientRects = filterOutTinyRects(clientRects); - clientRects = filterOutRectsContainedByOthers(clientRects); + clientRects = RectHelpers.filterOutTinyRects(clientRects); + clientRects = RectHelpers.filterOutRectsContainedByOthers(clientRects); clientRects = mergeTouchingClientRects(clientRects); return clientRects; } @@ -68,17 +61,17 @@ function mergeTouchingClientRects(clientRects) { const rectsLineUpVertically = almostEqual(crA.left, crB.left) || almostEqual(crA.right, crB.right); const canMerge = - rectsTouchOrOverlap(crA, crB) && + RectHelpers.rectsTouchOrOverlap(crA, crB) && (rectsLineUpHorizontally || rectsLineUpVertically); if (canMerge) { - const replacementClientRect = getBoundingRect([crA, crB]); - const mergedRectCenter = getRectCenterPoint(replacementClientRect); + const replacementClientRect = RectHelpers.getBoundingRect([crA, crB]); + const mergedRectCenter = RectHelpers.getRectCenterPoint(replacementClientRect); if ( !( - rectContainsPoint(crA, mergedRectCenter) || - rectContainsPoint(crB, mergedRectCenter) + RectHelpers.rectContainsPoint(crA, mergedRectCenter) || + RectHelpers.rectContainsPoint(crB, mergedRectCenter) ) ) { // Don't merge because the new shape is too different from the diff --git a/lighthouse-core/lib/url-shim.js b/lighthouse-core/lib/url-shim.js index 672ecb62c958..cb2256a35614 100644 --- a/lighthouse-core/lib/url-shim.js +++ b/lighthouse-core/lib/url-shim.js @@ -224,7 +224,7 @@ class URLShim extends URL { let url; try { url = new URL(src); - } catch { + } catch (e) { return undefined; } diff --git a/lighthouse-logger/index.js b/lighthouse-logger/index.js index 7ae6ea5a556e..7a70fbe7d078 100644 --- a/lighthouse-logger/index.js +++ b/lighthouse-logger/index.js @@ -5,8 +5,11 @@ */ 'use strict'; -const debug = require('debug'); +let debug = require('debug'); const marky = require('marky'); +const process = require('process'); + +if (debug.__moduleExports) debug = debug.__moduleExports; const EventEmitter = require('events').EventEmitter; const isWindows = process.platform === 'win32'; @@ -24,7 +27,11 @@ const colors = { }; // allow non-red/yellow colors for debug() -debug.colors = [colors.cyan, colors.green, colors.blue, colors.magenta]; +try { + debug.colors = [colors.cyan, colors.green, colors.blue, colors.magenta]; +} catch { + // Might be made readonly in rollup bundle. +} class Emitter extends EventEmitter { /** diff --git a/package.json b/package.json index b80d55e4baae..a3b2b173b454 100644 --- a/package.json +++ b/package.json @@ -26,7 +26,7 @@ "build-report": "node build/build-report.js", "build-treemap": "node ./build/build-treemap.js", "build-viewer": "node ./build/build-viewer.js", - "reset-link": "(yarn unlink || true) && yarn link && yarn link lighthouse", + "reset-link": "(yarn unlink || true) && yarn link && yarn link lighthouse && cd lighthouse-logger && (yarn unlink || true) && yarn link && cd .. && yarn link lighthouse-logger", "c8": "bash lighthouse-core/scripts/c8.sh", "clean": "rm -r dist proto/scripts/*.json proto/scripts/*_pb2.* proto/scripts/*_pb.* proto/scripts/__pycache__ proto/scripts/*.pyc *.report.html *.report.dom.html *.report.json *.devtoolslog.json *.trace.json lighthouse-core/lib/i18n/locales/*.ctc.json || true", "lint": "[ \"$CI\" = true ] && eslint --quiet -f codeframe . || eslint .", @@ -88,7 +88,6 @@ "serve-viewer": "yarn serve-gh-pages" }, "devDependencies": { - "@babel/preset-env": "^7.14.7", "@build-tracker/cli": "^1.0.0-beta.15", "@firebase/app-types": "0.3.1", "@firebase/auth-types": "0.3.2", @@ -125,7 +124,6 @@ "@wardpeet/brfs": "2.1.0", "angular": "^1.7.4", "archiver": "^3.0.0", - "babelify": "^10.0.0", "browserify": "^17.0.0", "browserify-banner": "^1.0.15", "bundle-phobia-cli": "^0.14.6", @@ -158,12 +156,15 @@ "pako": "^2.0.3", "pretty-json-stringify": "^0.0.2", "puppeteer": "^9.1.1", + "rollup": "^2.52.7", + "rollup-plugin-brfs": "^1.0.1", "rollup-plugin-commonjs": "^10.1.0", - "rollup-plugin-ignore": "^1.0.9", - "rollup-plugin-node-globals": "^1.4.0", + "rollup-plugin-node-builtins": "^2.1.2", "rollup-plugin-node-polyfills": "^0.2.1", "rollup-plugin-node-resolve": "^5.2.0", + "rollup-plugin-replace": "^2.2.0", "rollup-plugin-shim": "^1.0.0", + "rollup-plugin-terser": "^7.0.2", "tabulator-tables": "^4.9.3", "terser": "^5.3.8", "typed-query-selector": "^2.4.0", @@ -194,7 +195,6 @@ "ps-list": "^7.2.0", "raven": "^2.2.1", "robots-parser": "^2.0.1", - "rollup": "^2.52.6", "semver": "^5.3.0", "speedline-core": "^1.4.3", "third-party-web": "^0.12.2", diff --git a/report/assets/standalone-template.html b/report/assets/standalone-template.html index e7cd816d40c0..cca9e9913563 100644 --- a/report/assets/standalone-template.html +++ b/report/assets/standalone-template.html @@ -33,6 +33,7 @@ diff --git a/report/clients/standalone.js b/report/clients/standalone.js index b45511233c9d..35aa11551be9 100644 --- a/report/clients/standalone.js +++ b/report/clients/standalone.js @@ -7,7 +7,7 @@ /* global document window ga DOM ReportRenderer ReportUIFeatures Logger */ -(function __initLighthouseReport__() { +function __initLighthouseReport__() { const dom = new DOM(document); const renderer = new ReportRenderer(dom); const container = dom.find('main', document); @@ -20,33 +20,33 @@ // is in the document. const features = new ReportUIFeatures(dom); features.initFeatures(lhr); -})(); -document.addEventListener('lh-analytics', /** @param {Event} e */ e => { - // @ts-expect-error - if (window.ga) ga(e.detail.cmd, e.detail.fields); -}); + document.addEventListener('lh-analytics', /** @param {Event} e */ e => { + // @ts-expect-error + if (window.ga) ga(e.detail.cmd, e.detail.fields); + }); -document.addEventListener('lh-log', /** @param {Event} e */ e => { - const el = document.querySelector('#lh-log'); - if (!el) return; + document.addEventListener('lh-log', /** @param {Event} e */ e => { + const el = document.querySelector('#lh-log'); + if (!el) return; - const logger = new Logger(el); - // @ts-expect-error - const detail = e.detail; + const logger = new Logger(el); + // @ts-expect-error + const detail = e.detail; - switch (detail.cmd) { - case 'log': - logger.log(detail.msg); - break; - case 'warn': - logger.warn(detail.msg); - break; - case 'error': - logger.error(detail.msg); - break; - case 'hide': - logger.hide(); - break; - } -}); + switch (detail.cmd) { + case 'log': + logger.log(detail.msg); + break; + case 'warn': + logger.warn(detail.msg); + break; + case 'error': + logger.error(detail.msg); + break; + case 'hide': + logger.hide(); + break; + } + }); +} diff --git a/report/renderer/element-screenshot-renderer.js b/report/renderer/element-screenshot-renderer.js index bd635accdeb5..1f41b64d72e5 100644 --- a/report/renderer/element-screenshot-renderer.js +++ b/report/renderer/element-screenshot-renderer.js @@ -52,7 +52,7 @@ function clamp(value, min, max) { /** * @param {Rect} rect */ -function getRectCenterPoint(rect) { +function getElementRectCenterPoint(rect) { return { x: rect.left + rect.width / 2, y: rect.top + rect.height / 2, @@ -69,7 +69,7 @@ class ElementScreenshotRenderer { * @param {Size} screenshotSize */ static getScreenshotPositions(elementRectSC, elementPreviewSizeSC, screenshotSize) { - const elementRectCenter = getRectCenterPoint(elementRectSC); + const elementRectCenter = getElementRectCenterPoint(elementRectSC); // Try to center clipped region. const screenshotLeftVisibleEdge = clamp( diff --git a/yarn.lock b/yarn.lock index 8febcc8e4899..5d61950556dc 100644 --- a/yarn.lock +++ b/yarn.lock @@ -16,18 +16,13 @@ dependencies: "@babel/highlight" "^7.12.13" -"@babel/code-frame@^7.14.5": +"@babel/code-frame@^7.10.4": version "7.14.5" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.14.5.tgz#23b08d740e83f49c5e59945fbf1b43e80bbf4edb" integrity sha512-9pzDqyc6OLDaqe+zbACgFkb6fKMNG6CObKpnYXChRsvYGyEdc7CA2BaqeOM+vOtCS5ndmJicPJhKAwYRI6UfFw== dependencies: "@babel/highlight" "^7.14.5" -"@babel/compat-data@^7.13.11", "@babel/compat-data@^7.14.5", "@babel/compat-data@^7.14.7": - version "7.14.7" - resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.14.7.tgz#7b047d7a3a89a67d2258dc61f604f098f1bc7e08" - integrity sha512-nS6dZaISCXJ3+518CWiBfEr//gHyMO02uDxBkXTKZDN5POruCnOZ1N4YBRZDCabwF8nZMWBpRxIicmXtBs+fvw== - "@babel/compat-data@^7.13.12": version "7.13.15" resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.13.15.tgz#7e8eea42d0b64fda2b375b22d06c605222e848f4" @@ -107,40 +102,6 @@ jsesc "^2.5.1" source-map "^0.5.0" -"@babel/generator@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.14.5.tgz#848d7b9f031caca9d0cd0af01b063f226f52d785" - integrity sha512-y3rlP+/G25OIX3mYKKIOlQRcqj7YgrvHxOLbVmyLJ9bPmi5ttvUmpydVjcFjZphOktWuA7ovbx91ECloWTfjIA== - dependencies: - "@babel/types" "^7.14.5" - jsesc "^2.5.1" - source-map "^0.5.0" - -"@babel/helper-annotate-as-pure@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.14.5.tgz#7bf478ec3b71726d56a8ca5775b046fc29879e61" - integrity sha512-EivH9EgBIb+G8ij1B2jAwSH36WnGvkQSEC6CkX/6v6ZFlw5fVOHvsgGF4uiEHO2GzMvunZb6tDLQEQSdrdocrA== - dependencies: - "@babel/types" "^7.14.5" - -"@babel/helper-builder-binary-assignment-operator-visitor@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.14.5.tgz#b939b43f8c37765443a19ae74ad8b15978e0a191" - integrity sha512-YTA/Twn0vBXDVGJuAX6PwW7x5zQei1luDDo2Pl6q1qZ7hVNl0RZrhHCQG/ArGpR29Vl7ETiB8eJyrvpuRp300w== - dependencies: - "@babel/helper-explode-assignable-expression" "^7.14.5" - "@babel/types" "^7.14.5" - -"@babel/helper-compilation-targets@^7.13.0", "@babel/helper-compilation-targets@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.14.5.tgz#7a99c5d0967911e972fe2c3411f7d5b498498ecf" - integrity sha512-v+QtZqXEiOnpO6EYvlImB6zCD2Lel06RzOPzmkz/D/XgQiUu3C/Jb1LOqSt/AIA34TYi/Q+KlT8vTQrgdxkbLw== - dependencies: - "@babel/compat-data" "^7.14.5" - "@babel/helper-validator-option" "^7.14.5" - browserslist "^4.16.6" - semver "^6.3.0" - "@babel/helper-compilation-targets@^7.13.13": version "7.13.13" resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.13.13.tgz#2b2972a0926474853f41e4adbc69338f520600e5" @@ -161,47 +122,6 @@ browserslist "^4.16.6" semver "^6.3.0" -"@babel/helper-create-class-features-plugin@^7.14.5": - version "7.14.6" - resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.14.6.tgz#f114469b6c06f8b5c59c6c4e74621f5085362542" - integrity sha512-Z6gsfGofTxH/+LQXqYEK45kxmcensbzmk/oi8DmaQytlQCgqNZt9XQF8iqlI/SeXWVjaMNxvYvzaYw+kh42mDg== - dependencies: - "@babel/helper-annotate-as-pure" "^7.14.5" - "@babel/helper-function-name" "^7.14.5" - "@babel/helper-member-expression-to-functions" "^7.14.5" - "@babel/helper-optimise-call-expression" "^7.14.5" - "@babel/helper-replace-supers" "^7.14.5" - "@babel/helper-split-export-declaration" "^7.14.5" - -"@babel/helper-create-regexp-features-plugin@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.14.5.tgz#c7d5ac5e9cf621c26057722fb7a8a4c5889358c4" - integrity sha512-TLawwqpOErY2HhWbGJ2nZT5wSkR192QpN+nBg1THfBfftrlvOh+WbhrxXCH4q4xJ9Gl16BGPR/48JA+Ryiho/A== - dependencies: - "@babel/helper-annotate-as-pure" "^7.14.5" - regexpu-core "^4.7.1" - -"@babel/helper-define-polyfill-provider@^0.2.2": - version "0.2.3" - resolved "https://registry.yarnpkg.com/@babel/helper-define-polyfill-provider/-/helper-define-polyfill-provider-0.2.3.tgz#0525edec5094653a282688d34d846e4c75e9c0b6" - integrity sha512-RH3QDAfRMzj7+0Nqu5oqgO5q9mFtQEVvCRsi8qCEfzLR9p2BHfn5FzhSB2oj1fF7I2+DcTORkYaQ6aTR9Cofew== - dependencies: - "@babel/helper-compilation-targets" "^7.13.0" - "@babel/helper-module-imports" "^7.12.13" - "@babel/helper-plugin-utils" "^7.13.0" - "@babel/traverse" "^7.13.0" - debug "^4.1.1" - lodash.debounce "^4.0.8" - resolve "^1.14.2" - semver "^6.1.2" - -"@babel/helper-explode-assignable-expression@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.14.5.tgz#8aa72e708205c7bb643e45c73b4386cdf2a1f645" - integrity sha512-Htb24gnGJdIGT4vnRKMdoXiOIlqOLmdiUYpAQ0mYfgVT/GDm8GOYhgi4GL+hMKrkiPRohO4ts34ELFsGAPQLDQ== - dependencies: - "@babel/types" "^7.14.5" - "@babel/helper-function-name@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.12.13.tgz#93ad656db3c3c2232559fd7b2c3dbdcbe0eb377a" @@ -220,15 +140,6 @@ "@babel/template" "^7.12.13" "@babel/types" "^7.14.2" -"@babel/helper-function-name@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.14.5.tgz#89e2c474972f15d8e233b52ee8c480e2cfcd50c4" - integrity sha512-Gjna0AsXWfFvrAuX+VKcN/aNNWonizBj39yGwUzVDVTlMYJMK2Wp6xdpy72mfArFq5uK+NOuexfzZlzI1z9+AQ== - dependencies: - "@babel/helper-get-function-arity" "^7.14.5" - "@babel/template" "^7.14.5" - "@babel/types" "^7.14.5" - "@babel/helper-get-function-arity@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.12.13.tgz#bc63451d403a3b3082b97e1d8b3fe5bd4091e583" @@ -236,20 +147,6 @@ dependencies: "@babel/types" "^7.12.13" -"@babel/helper-get-function-arity@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.14.5.tgz#25fbfa579b0937eee1f3b805ece4ce398c431815" - integrity sha512-I1Db4Shst5lewOM4V+ZKJzQ0JGGaZ6VY1jYvMghRjqs6DWgxLCIyFt30GlnKkfUeFLpJt2vzbMVEXVSXlIFYUg== - dependencies: - "@babel/types" "^7.14.5" - -"@babel/helper-hoist-variables@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.14.5.tgz#e0dd27c33a78e577d7c8884916a3e7ef1f7c7f8d" - integrity sha512-R1PXiz31Uc0Vxy4OEOm07x0oSjKAdPPCh3tPivn/Eo8cvz6gveAeuyUUPB21Hoiif0uoPQSSdhIPS3352nvdyQ== - dependencies: - "@babel/types" "^7.14.5" - "@babel/helper-member-expression-to-functions@^7.13.12": version "7.13.12" resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.13.12.tgz#dfe368f26d426a07299d8d6513821768216e6d72" @@ -257,20 +154,6 @@ dependencies: "@babel/types" "^7.13.12" -"@babel/helper-member-expression-to-functions@^7.14.5": - version "7.14.7" - resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.14.7.tgz#97e56244beb94211fe277bd818e3a329c66f7970" - integrity sha512-TMUt4xKxJn6ccjcOW7c4hlwyJArizskAhoSTOCkA0uZ+KghIaci0Qg9R043kUMWI9mtQfgny+NQ5QATnZ+paaA== - dependencies: - "@babel/types" "^7.14.5" - -"@babel/helper-module-imports@^7.12.13", "@babel/helper-module-imports@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.14.5.tgz#6d1a44df6a38c957aa7c312da076429f11b422f3" - integrity sha512-SwrNHu5QWS84XlHwGYPDtCxcA0hrSlL2yhWYLgeOc0w7ccOl2qv4s/nARI0aYZW+bSwAL5CukeXA47B/1NKcnQ== - dependencies: - "@babel/types" "^7.14.5" - "@babel/helper-module-imports@^7.13.12": version "7.13.12" resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.13.12.tgz#c6a369a6f3621cb25da014078684da9196b61977" @@ -306,20 +189,6 @@ "@babel/traverse" "^7.14.2" "@babel/types" "^7.14.2" -"@babel/helper-module-transforms@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.14.5.tgz#7de42f10d789b423eb902ebd24031ca77cb1e10e" - integrity sha512-iXpX4KW8LVODuAieD7MzhNjmM6dzYY5tfRqT+R9HDXWl0jPn/djKmA+G9s/2C2T9zggw5tK1QNqZ70USfedOwA== - dependencies: - "@babel/helper-module-imports" "^7.14.5" - "@babel/helper-replace-supers" "^7.14.5" - "@babel/helper-simple-access" "^7.14.5" - "@babel/helper-split-export-declaration" "^7.14.5" - "@babel/helper-validator-identifier" "^7.14.5" - "@babel/template" "^7.14.5" - "@babel/traverse" "^7.14.5" - "@babel/types" "^7.14.5" - "@babel/helper-optimise-call-expression@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.12.13.tgz#5c02d171b4c8615b1e7163f888c1c81c30a2aaea" @@ -327,32 +196,11 @@ dependencies: "@babel/types" "^7.12.13" -"@babel/helper-optimise-call-expression@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.14.5.tgz#f27395a8619e0665b3f0364cddb41c25d71b499c" - integrity sha512-IqiLIrODUOdnPU9/F8ib1Fx2ohlgDhxnIDU7OEVi+kAbEZcyiF7BLU8W6PfvPi9LzztjS7kcbzbmL7oG8kD6VA== - dependencies: - "@babel/types" "^7.14.5" - "@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.8.0": version "7.13.0" resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.13.0.tgz#806526ce125aed03373bc416a828321e3a6a33af" integrity sha512-ZPafIPSwzUlAoWT8DKs1W2VyF2gOWthGd5NGFMsBcMMol+ZhK+EQY/e6V96poa6PA/Bh+C9plWN0hXO1uB8AfQ== -"@babel/helper-plugin-utils@^7.13.0", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.8.3": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.14.5.tgz#5ac822ce97eec46741ab70a517971e443a70c5a9" - integrity sha512-/37qQCE3K0vvZKwoK4XU/irIJQdIfCJuhU5eKnNxpFDsOkgFaUAwbv+RYw6eYgsC0E4hS7r5KqGULUogqui0fQ== - -"@babel/helper-remap-async-to-generator@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.14.5.tgz#51439c913612958f54a987a4ffc9ee587a2045d6" - integrity sha512-rLQKdQU+HYlxBwQIj8dk4/0ENOUEhA/Z0l4hN8BexpvmSMN9oA9EagjnhnDpNsRdWCfjwa4mn/HyBXO9yhQP6A== - dependencies: - "@babel/helper-annotate-as-pure" "^7.14.5" - "@babel/helper-wrap-function" "^7.14.5" - "@babel/types" "^7.14.5" - "@babel/helper-replace-supers@^7.13.12": version "7.13.12" resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.13.12.tgz#6442f4c1ad912502481a564a7386de0c77ff3804" @@ -363,16 +211,6 @@ "@babel/traverse" "^7.13.0" "@babel/types" "^7.13.12" -"@babel/helper-replace-supers@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.14.5.tgz#0ecc0b03c41cd567b4024ea016134c28414abb94" - integrity sha512-3i1Qe9/8x/hCHINujn+iuHy+mMRLoc77b2nI9TB0zjH1hvn9qGlXjWlggdwUcju36PkPCy/lpM7LLUdcTyH4Ow== - dependencies: - "@babel/helper-member-expression-to-functions" "^7.14.5" - "@babel/helper-optimise-call-expression" "^7.14.5" - "@babel/traverse" "^7.14.5" - "@babel/types" "^7.14.5" - "@babel/helper-simple-access@^7.13.12": version "7.13.12" resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.13.12.tgz#dd6c538afb61819d205a012c31792a39c7a5eaf6" @@ -380,20 +218,6 @@ dependencies: "@babel/types" "^7.13.12" -"@babel/helper-simple-access@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.14.5.tgz#66ea85cf53ba0b4e588ba77fc813f53abcaa41c4" - integrity sha512-nfBN9xvmCt6nrMZjfhkl7i0oTV3yxR4/FztsbOASyTvVcoYd0TRHh7eMLdlEcCqobydC0LAF3LtC92Iwxo0wyw== - dependencies: - "@babel/types" "^7.14.5" - -"@babel/helper-skip-transparent-expression-wrappers@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.14.5.tgz#96f486ac050ca9f44b009fbe5b7d394cab3a0ee4" - integrity sha512-dmqZB7mrb94PZSAOYtr+ZN5qt5owZIAgqtoTuqiFbHFtxgEcmQlRJVI+bO++fciBunXtB6MK7HrzrfcAzIz2NQ== - dependencies: - "@babel/types" "^7.14.5" - "@babel/helper-split-export-declaration@^7.12.13": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.12.13.tgz#e9430be00baf3e88b0e13e6f9d4eaf2136372b05" @@ -401,13 +225,6 @@ dependencies: "@babel/types" "^7.12.13" -"@babel/helper-split-export-declaration@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.14.5.tgz#22b23a54ef51c2b7605d851930c1976dd0bc693a" - integrity sha512-hprxVPu6e5Kdp2puZUmvOGjaLv9TCe58E/Fl6hRq4YiVQxIcNvuq6uTM2r1mT/oPskuS9CgR+I94sqAYv0NGKA== - dependencies: - "@babel/types" "^7.14.5" - "@babel/helper-validator-identifier@^7.12.11": version "7.12.11" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.12.11.tgz#c9a1f021917dcb5ccf0d4e453e399022981fc9ed" @@ -428,21 +245,6 @@ resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.12.17.tgz#d1fbf012e1a79b7eebbfdc6d270baaf8d9eb9831" integrity sha512-TopkMDmLzq8ngChwRlyjR6raKD6gMSae4JdYDB8bByKreQgG0RBTuKe9LRxW3wFtUnjxOPRKBDwEH6Mg5KeDfw== -"@babel/helper-validator-option@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.14.5.tgz#6e72a1fff18d5dfcb878e1e62f1a021c4b72d5a3" - integrity sha512-OX8D5eeX4XwcroVW45NMvoYaIuFI+GQpA2a8Gi+X/U/cDUIRsV37qQfF905F0htTRCREQIB4KqPeaveRJUl3Ow== - -"@babel/helper-wrap-function@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.14.5.tgz#5919d115bf0fe328b8a5d63bcb610f51601f2bff" - integrity sha512-YEdjTCq+LNuNS1WfxsDCNpgXkJaIyqco6DAelTUjT4f2KIWC1nBcaCaSdHTBqQVLnTBexBcVcFhLSU1KnYuePQ== - dependencies: - "@babel/helper-function-name" "^7.14.5" - "@babel/template" "^7.14.5" - "@babel/traverse" "^7.14.5" - "@babel/types" "^7.14.5" - "@babel/helpers@^7.13.10": version "7.13.10" resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.13.10.tgz#fd8e2ba7488533cdeac45cc158e9ebca5e3c7df8" @@ -494,148 +296,6 @@ resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.14.4.tgz#a5c560d6db6cd8e6ed342368dea8039232cbab18" integrity sha512-ArliyUsWDUqEGfWcmzpGUzNfLxTdTp6WU4IuP6QFSp9gGfWS6boxFCkJSJ/L4+RG8z/FnIU3WxCk6hPL9SSWeA== -"@babel/parser@^7.14.5", "@babel/parser@^7.14.7": - version "7.14.7" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.14.7.tgz#6099720c8839ca865a2637e6c85852ead0bdb595" - integrity sha512-X67Z5y+VBJuHB/RjwECp8kSl5uYi0BvRbNeWqkaJCVh+LiTPl19WBUfG627psSgp9rSf6ojuXghQM3ha6qHHdA== - -"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining/-/plugin-bugfix-v8-spread-parameters-in-optional-chaining-7.14.5.tgz#4b467302e1548ed3b1be43beae2cc9cf45e0bb7e" - integrity sha512-ZoJS2XCKPBfTmL122iP6NM9dOg+d4lc9fFk3zxc8iDjvt8Pk4+TlsHSKhIPf6X+L5ORCdBzqMZDjL/WHj7WknQ== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/helper-skip-transparent-expression-wrappers" "^7.14.5" - "@babel/plugin-proposal-optional-chaining" "^7.14.5" - -"@babel/plugin-proposal-async-generator-functions@^7.14.7": - version "7.14.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.14.7.tgz#784a48c3d8ed073f65adcf30b57bcbf6c8119ace" - integrity sha512-RK8Wj7lXLY3bqei69/cc25gwS5puEc3dknoFPFbqfy3XxYQBQFvu4ioWpafMBAB+L9NyptQK4nMOa5Xz16og8Q== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/helper-remap-async-to-generator" "^7.14.5" - "@babel/plugin-syntax-async-generators" "^7.8.4" - -"@babel/plugin-proposal-class-properties@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.14.5.tgz#40d1ee140c5b1e31a350f4f5eed945096559b42e" - integrity sha512-q/PLpv5Ko4dVc1LYMpCY7RVAAO4uk55qPwrIuJ5QJ8c6cVuAmhu7I/49JOppXL6gXf7ZHzpRVEUZdYoPLM04Gg== - dependencies: - "@babel/helper-create-class-features-plugin" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-proposal-class-static-block@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-static-block/-/plugin-proposal-class-static-block-7.14.5.tgz#158e9e10d449c3849ef3ecde94a03d9f1841b681" - integrity sha512-KBAH5ksEnYHCegqseI5N9skTdxgJdmDoAOc0uXa+4QMYKeZD0w5IARh4FMlTNtaHhbB8v+KzMdTgxMMzsIy6Yg== - dependencies: - "@babel/helper-create-class-features-plugin" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-class-static-block" "^7.14.5" - -"@babel/plugin-proposal-dynamic-import@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.14.5.tgz#0c6617df461c0c1f8fff3b47cd59772360101d2c" - integrity sha512-ExjiNYc3HDN5PXJx+bwC50GIx/KKanX2HiggnIUAYedbARdImiCU4RhhHfdf0Kd7JNXGpsBBBCOm+bBVy3Gb0g== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-dynamic-import" "^7.8.3" - -"@babel/plugin-proposal-export-namespace-from@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-export-namespace-from/-/plugin-proposal-export-namespace-from-7.14.5.tgz#dbad244310ce6ccd083072167d8cea83a52faf76" - integrity sha512-g5POA32bXPMmSBu5Dx/iZGLGnKmKPc5AiY7qfZgurzrCYgIztDlHFbznSNCoQuv57YQLnQfaDi7dxCtLDIdXdA== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-export-namespace-from" "^7.8.3" - -"@babel/plugin-proposal-json-strings@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.14.5.tgz#38de60db362e83a3d8c944ac858ddf9f0c2239eb" - integrity sha512-NSq2fczJYKVRIsUJyNxrVUMhB27zb7N7pOFGQOhBKJrChbGcgEAqyZrmZswkPk18VMurEeJAaICbfm57vUeTbQ== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-json-strings" "^7.8.3" - -"@babel/plugin-proposal-logical-assignment-operators@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-logical-assignment-operators/-/plugin-proposal-logical-assignment-operators-7.14.5.tgz#6e6229c2a99b02ab2915f82571e0cc646a40c738" - integrity sha512-YGn2AvZAo9TwyhlLvCCWxD90Xq8xJ4aSgaX3G5D/8DW94L8aaT+dS5cSP+Z06+rCJERGSr9GxMBZ601xoc2taw== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" - -"@babel/plugin-proposal-nullish-coalescing-operator@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.14.5.tgz#ee38589ce00e2cc59b299ec3ea406fcd3a0fdaf6" - integrity sha512-gun/SOnMqjSb98Nkaq2rTKMwervfdAoz6NphdY0vTfuzMfryj+tDGb2n6UkDKwez+Y8PZDhE3D143v6Gepp4Hg== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" - -"@babel/plugin-proposal-numeric-separator@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.14.5.tgz#83631bf33d9a51df184c2102a069ac0c58c05f18" - integrity sha512-yiclALKe0vyZRZE0pS6RXgjUOt87GWv6FYa5zqj15PvhOGFO69R5DusPlgK/1K5dVnCtegTiWu9UaBSrLLJJBg== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-numeric-separator" "^7.10.4" - -"@babel/plugin-proposal-object-rest-spread@^7.14.7": - version "7.14.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.14.7.tgz#5920a2b3df7f7901df0205974c0641b13fd9d363" - integrity sha512-082hsZz+sVabfmDWo1Oct1u1AgbKbUAyVgmX4otIc7bdsRgHBXwTwb3DpDmD4Eyyx6DNiuz5UAATT655k+kL5g== - dependencies: - "@babel/compat-data" "^7.14.7" - "@babel/helper-compilation-targets" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-object-rest-spread" "^7.8.3" - "@babel/plugin-transform-parameters" "^7.14.5" - -"@babel/plugin-proposal-optional-catch-binding@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.14.5.tgz#939dd6eddeff3a67fdf7b3f044b5347262598c3c" - integrity sha512-3Oyiixm0ur7bzO5ybNcZFlmVsygSIQgdOa7cTfOYCMY+wEPAYhZAJxi3mixKFCTCKUhQXuCTtQ1MzrpL3WT8ZQ== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" - -"@babel/plugin-proposal-optional-chaining@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.14.5.tgz#fa83651e60a360e3f13797eef00b8d519695b603" - integrity sha512-ycz+VOzo2UbWNI1rQXxIuMOzrDdHGrI23fRiz/Si2R4kv2XZQ1BK8ccdHwehMKBlcH/joGW/tzrUmo67gbJHlQ== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/helper-skip-transparent-expression-wrappers" "^7.14.5" - "@babel/plugin-syntax-optional-chaining" "^7.8.3" - -"@babel/plugin-proposal-private-methods@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-methods/-/plugin-proposal-private-methods-7.14.5.tgz#37446495996b2945f30f5be5b60d5e2aa4f5792d" - integrity sha512-838DkdUA1u+QTCplatfq4B7+1lnDa/+QMI89x5WZHBcnNv+47N8QEj2k9I2MUU9xIv8XJ4XvPCviM/Dj7Uwt9g== - dependencies: - "@babel/helper-create-class-features-plugin" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-proposal-private-property-in-object@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-private-property-in-object/-/plugin-proposal-private-property-in-object-7.14.5.tgz#9f65a4d0493a940b4c01f8aa9d3f1894a587f636" - integrity sha512-62EyfyA3WA0mZiF2e2IV9mc9Ghwxcg8YTu8BS4Wss4Y3PY725OmS9M0qLORbJwLqFtGh+jiE4wAmocK2CTUK2Q== - dependencies: - "@babel/helper-annotate-as-pure" "^7.14.5" - "@babel/helper-create-class-features-plugin" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-private-property-in-object" "^7.14.5" - -"@babel/plugin-proposal-unicode-property-regex@^7.14.5", "@babel/plugin-proposal-unicode-property-regex@^7.4.4": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.14.5.tgz#0f95ee0e757a5d647f378daa0eca7e93faa8bbe8" - integrity sha512-6axIeOU5LnY471KenAB9vI8I5j7NQ2d652hIYwVyRfgaZT5UpiqFKCuVXCDMSrU+3VFafnu2c5m3lrWIlr6A5Q== - dependencies: - "@babel/helper-create-regexp-features-plugin" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-async-generators@^7.8.4": version "7.8.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" @@ -650,34 +310,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-class-properties@^7.12.13", "@babel/plugin-syntax-class-properties@^7.8.3": +"@babel/plugin-syntax-class-properties@^7.8.3": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz#b5c987274c4a3a82b89714796931a6b53544ae10" integrity sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA== dependencies: "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-syntax-class-static-block@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-class-static-block/-/plugin-syntax-class-static-block-7.14.5.tgz#195df89b146b4b78b3bf897fd7a257c84659d406" - integrity sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-syntax-dynamic-import@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz#62bf98b2da3cd21d626154fc96ee5b3cb68eacb3" - integrity sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ== - dependencies: - "@babel/helper-plugin-utils" "^7.8.0" - -"@babel/plugin-syntax-export-namespace-from@^7.8.3": - version "7.8.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-export-namespace-from/-/plugin-syntax-export-namespace-from-7.8.3.tgz#028964a9ba80dbc094c915c487ad7c4e7a66465a" - integrity sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q== - dependencies: - "@babel/helper-plugin-utils" "^7.8.3" - "@babel/plugin-syntax-import-meta@^7.8.3": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz#ee601348c370fa334d2207be158777496521fd51" @@ -692,7 +331,7 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-logical-assignment-operators@^7.10.4", "@babel/plugin-syntax-logical-assignment-operators@^7.8.3": +"@babel/plugin-syntax-logical-assignment-operators@^7.8.3": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz#ca91ef46303530448b906652bac2e9fe9941f699" integrity sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig== @@ -706,7 +345,7 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-numeric-separator@^7.10.4", "@babel/plugin-syntax-numeric-separator@^7.8.3": +"@babel/plugin-syntax-numeric-separator@^7.8.3": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz#b9b070b3e33570cd9fd07ba7fa91c0dd37b9af97" integrity sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug== @@ -734,20 +373,6 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-private-property-in-object@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-private-property-in-object/-/plugin-syntax-private-property-in-object-7.14.5.tgz#0dc6671ec0ea22b6e94a1114f857970cd39de1ad" - integrity sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-syntax-top-level-await@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz#c1cfdadc35a646240001f06138247b741c34d94c" - integrity sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/plugin-syntax-top-level-await@^7.8.3": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.12.13.tgz#c5f0fa6e249f5b739727f923540cf7a806130178" @@ -762,351 +387,6 @@ dependencies: "@babel/helper-plugin-utils" "^7.12.13" -"@babel/plugin-transform-arrow-functions@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.14.5.tgz#f7187d9588a768dd080bf4c9ffe117ea62f7862a" - integrity sha512-KOnO0l4+tD5IfOdi4x8C1XmEIRWUjNRV8wc6K2vz/3e8yAOoZZvsRXRRIF/yo/MAOFb4QjtAw9xSxMXbSMRy8A== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-async-to-generator@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.14.5.tgz#72c789084d8f2094acb945633943ef8443d39e67" - integrity sha512-szkbzQ0mNk0rpu76fzDdqSyPu0MuvpXgC+6rz5rpMb5OIRxdmHfQxrktL8CYolL2d8luMCZTR0DpIMIdL27IjA== - dependencies: - "@babel/helper-module-imports" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/helper-remap-async-to-generator" "^7.14.5" - -"@babel/plugin-transform-block-scoped-functions@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.14.5.tgz#e48641d999d4bc157a67ef336aeb54bc44fd3ad4" - integrity sha512-dtqWqdWZ5NqBX3KzsVCWfQI3A53Ft5pWFCT2eCVUftWZgjc5DpDponbIF1+c+7cSGk2wN0YK7HGL/ezfRbpKBQ== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-block-scoping@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.14.5.tgz#8cc63e61e50f42e078e6f09be775a75f23ef9939" - integrity sha512-LBYm4ZocNgoCqyxMLoOnwpsmQ18HWTQvql64t3GvMUzLQrNoV1BDG0lNftC8QKYERkZgCCT/7J5xWGObGAyHDw== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-classes@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.14.5.tgz#0e98e82097b38550b03b483f9b51a78de0acb2cf" - integrity sha512-J4VxKAMykM06K/64z9rwiL6xnBHgB1+FVspqvlgCdwD1KUbQNfszeKVVOMh59w3sztHYIZDgnhOC4WbdEfHFDA== - dependencies: - "@babel/helper-annotate-as-pure" "^7.14.5" - "@babel/helper-function-name" "^7.14.5" - "@babel/helper-optimise-call-expression" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/helper-replace-supers" "^7.14.5" - "@babel/helper-split-export-declaration" "^7.14.5" - globals "^11.1.0" - -"@babel/plugin-transform-computed-properties@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.14.5.tgz#1b9d78987420d11223d41195461cc43b974b204f" - integrity sha512-pWM+E4283UxaVzLb8UBXv4EIxMovU4zxT1OPnpHJcmnvyY9QbPPTKZfEj31EUvG3/EQRbYAGaYEUZ4yWOBC2xg== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-destructuring@^7.14.7": - version "7.14.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.14.7.tgz#0ad58ed37e23e22084d109f185260835e5557576" - integrity sha512-0mDE99nK+kVh3xlc5vKwB6wnP9ecuSj+zQCa/n0voENtP/zymdT4HH6QEb65wjjcbqr1Jb/7z9Qp7TF5FtwYGw== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-dotall-regex@^7.14.5", "@babel/plugin-transform-dotall-regex@^7.4.4": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.14.5.tgz#2f6bf76e46bdf8043b4e7e16cf24532629ba0c7a" - integrity sha512-loGlnBdj02MDsFaHhAIJzh7euK89lBrGIdM9EAtHFo6xKygCUGuuWe07o1oZVk287amtW1n0808sQM99aZt3gw== - dependencies: - "@babel/helper-create-regexp-features-plugin" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-duplicate-keys@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.14.5.tgz#365a4844881bdf1501e3a9f0270e7f0f91177954" - integrity sha512-iJjbI53huKbPDAsJ8EmVmvCKeeq21bAze4fu9GBQtSLqfvzj2oRuHVx4ZkDwEhg1htQ+5OBZh/Ab0XDf5iBZ7A== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-exponentiation-operator@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.14.5.tgz#5154b8dd6a3dfe6d90923d61724bd3deeb90b493" - integrity sha512-jFazJhMBc9D27o9jDnIE5ZErI0R0m7PbKXVq77FFvqFbzvTMuv8jaAwLZ5PviOLSFttqKIW0/wxNSDbjLk0tYA== - dependencies: - "@babel/helper-builder-binary-assignment-operator-visitor" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-for-of@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.14.5.tgz#dae384613de8f77c196a8869cbf602a44f7fc0eb" - integrity sha512-CfmqxSUZzBl0rSjpoQSFoR9UEj3HzbGuGNL21/iFTmjb5gFggJp3ph0xR1YBhexmLoKRHzgxuFvty2xdSt6gTA== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-function-name@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.14.5.tgz#e81c65ecb900746d7f31802f6bed1f52d915d6f2" - integrity sha512-vbO6kv0fIzZ1GpmGQuvbwwm+O4Cbm2NrPzwlup9+/3fdkuzo1YqOZcXw26+YUJB84Ja7j9yURWposEHLYwxUfQ== - dependencies: - "@babel/helper-function-name" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-literals@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.14.5.tgz#41d06c7ff5d4d09e3cf4587bd3ecf3930c730f78" - integrity sha512-ql33+epql2F49bi8aHXxvLURHkxJbSmMKl9J5yHqg4PLtdE6Uc48CH1GS6TQvZ86eoB/ApZXwm7jlA+B3kra7A== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-member-expression-literals@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.14.5.tgz#b39cd5212a2bf235a617d320ec2b48bcc091b8a7" - integrity sha512-WkNXxH1VXVTKarWFqmso83xl+2V3Eo28YY5utIkbsmXoItO8Q3aZxN4BTS2k0hz9dGUloHK26mJMyQEYfkn/+Q== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-modules-amd@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.14.5.tgz#4fd9ce7e3411cb8b83848480b7041d83004858f7" - integrity sha512-3lpOU8Vxmp3roC4vzFpSdEpGUWSMsHFreTWOMMLzel2gNGfHE5UWIh/LN6ghHs2xurUp4jRFYMUIZhuFbody1g== - dependencies: - "@babel/helper-module-transforms" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - babel-plugin-dynamic-import-node "^2.3.3" - -"@babel/plugin-transform-modules-commonjs@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.14.5.tgz#7aaee0ea98283de94da98b28f8c35701429dad97" - integrity sha512-en8GfBtgnydoao2PS+87mKyw62k02k7kJ9ltbKe0fXTHrQmG6QZZflYuGI1VVG7sVpx4E1n7KBpNlPb8m78J+A== - dependencies: - "@babel/helper-module-transforms" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/helper-simple-access" "^7.14.5" - babel-plugin-dynamic-import-node "^2.3.3" - -"@babel/plugin-transform-modules-systemjs@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.14.5.tgz#c75342ef8b30dcde4295d3401aae24e65638ed29" - integrity sha512-mNMQdvBEE5DcMQaL5LbzXFMANrQjd2W7FPzg34Y4yEz7dBgdaC+9B84dSO+/1Wba98zoDbInctCDo4JGxz1VYA== - dependencies: - "@babel/helper-hoist-variables" "^7.14.5" - "@babel/helper-module-transforms" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/helper-validator-identifier" "^7.14.5" - babel-plugin-dynamic-import-node "^2.3.3" - -"@babel/plugin-transform-modules-umd@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.14.5.tgz#fb662dfee697cce274a7cda525190a79096aa6e0" - integrity sha512-RfPGoagSngC06LsGUYyM9QWSXZ8MysEjDJTAea1lqRjNECE3y0qIJF/qbvJxc4oA4s99HumIMdXOrd+TdKaAAA== - dependencies: - "@babel/helper-module-transforms" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-named-capturing-groups-regex@^7.14.7": - version "7.14.7" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.14.7.tgz#60c06892acf9df231e256c24464bfecb0908fd4e" - integrity sha512-DTNOTaS7TkW97xsDMrp7nycUVh6sn/eq22VaxWfEdzuEbRsiaOU0pqU7DlyUGHVsbQbSghvjKRpEl+nUCKGQSg== - dependencies: - "@babel/helper-create-regexp-features-plugin" "^7.14.5" - -"@babel/plugin-transform-new-target@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.14.5.tgz#31bdae8b925dc84076ebfcd2a9940143aed7dbf8" - integrity sha512-Nx054zovz6IIRWEB49RDRuXGI4Gy0GMgqG0cII9L3MxqgXz/+rgII+RU58qpo4g7tNEx1jG7rRVH4ihZoP4esQ== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-object-super@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.14.5.tgz#d0b5faeac9e98597a161a9cf78c527ed934cdc45" - integrity sha512-MKfOBWzK0pZIrav9z/hkRqIk/2bTv9qvxHzPQc12RcVkMOzpIKnFCNYJip00ssKWYkd8Sf5g0Wr7pqJ+cmtuFg== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/helper-replace-supers" "^7.14.5" - -"@babel/plugin-transform-parameters@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.14.5.tgz#49662e86a1f3ddccac6363a7dfb1ff0a158afeb3" - integrity sha512-Tl7LWdr6HUxTmzQtzuU14SqbgrSKmaR77M0OKyq4njZLQTPfOvzblNKyNkGwOfEFCEx7KeYHQHDI0P3F02IVkA== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-property-literals@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.14.5.tgz#0ddbaa1f83db3606f1cdf4846fa1dfb473458b34" - integrity sha512-r1uilDthkgXW8Z1vJz2dKYLV1tuw2xsbrp3MrZmD99Wh9vsfKoob+JTgri5VUb/JqyKRXotlOtwgu4stIYCmnw== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-regenerator@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.14.5.tgz#9676fd5707ed28f522727c5b3c0aa8544440b04f" - integrity sha512-NVIY1W3ITDP5xQl50NgTKlZ0GrotKtLna08/uGY6ErQt6VEQZXla86x/CTddm5gZdcr+5GSsvMeTmWA5Ii6pkg== - dependencies: - regenerator-transform "^0.14.2" - -"@babel/plugin-transform-reserved-words@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.14.5.tgz#c44589b661cfdbef8d4300dcc7469dffa92f8304" - integrity sha512-cv4F2rv1nD4qdexOGsRQXJrOcyb5CrgjUH9PKrrtyhSDBNWGxd0UIitjyJiWagS+EbUGjG++22mGH1Pub8D6Vg== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-shorthand-properties@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.14.5.tgz#97f13855f1409338d8cadcbaca670ad79e091a58" - integrity sha512-xLucks6T1VmGsTB+GWK5Pl9Jl5+nRXD1uoFdA5TSO6xtiNjtXTjKkmPdFXVLGlK5A2/or/wQMKfmQ2Y0XJfn5g== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-spread@^7.14.6": - version "7.14.6" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.14.6.tgz#6bd40e57fe7de94aa904851963b5616652f73144" - integrity sha512-Zr0x0YroFJku7n7+/HH3A2eIrGMjbmAIbJSVv0IZ+t3U2WUQUA64S/oeied2e+MaGSjmt4alzBCsK9E8gh+fag== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/helper-skip-transparent-expression-wrappers" "^7.14.5" - -"@babel/plugin-transform-sticky-regex@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.14.5.tgz#5b617542675e8b7761294381f3c28c633f40aeb9" - integrity sha512-Z7F7GyvEMzIIbwnziAZmnSNpdijdr4dWt+FJNBnBLz5mwDFkqIXU9wmBcWWad3QeJF5hMTkRe4dAq2sUZiG+8A== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-template-literals@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.14.5.tgz#a5f2bc233937d8453885dc736bdd8d9ffabf3d93" - integrity sha512-22btZeURqiepOfuy/VkFr+zStqlujWaarpMErvay7goJS6BWwdd6BY9zQyDLDa4x2S3VugxFb162IZ4m/S/+Gg== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-typeof-symbol@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.14.5.tgz#39af2739e989a2bd291bf6b53f16981423d457d4" - integrity sha512-lXzLD30ffCWseTbMQzrvDWqljvZlHkXU+CnseMhkMNqU1sASnCsz3tSzAaH3vCUXb9PHeUb90ZT1BdFTm1xxJw== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-unicode-escapes@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.14.5.tgz#9d4bd2a681e3c5d7acf4f57fa9e51175d91d0c6b" - integrity sha512-crTo4jATEOjxj7bt9lbYXcBAM3LZaUrbP2uUdxb6WIorLmjNKSpHfIybgY4B8SRpbf8tEVIWH3Vtm7ayCrKocA== - dependencies: - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/plugin-transform-unicode-regex@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.14.5.tgz#4cd09b6c8425dd81255c7ceb3fb1836e7414382e" - integrity sha512-UygduJpC5kHeCiRw/xDVzC+wj8VaYSoKl5JNVmbP7MadpNinAm3SvZCxZ42H37KZBKztz46YC73i9yV34d0Tzw== - dependencies: - "@babel/helper-create-regexp-features-plugin" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - -"@babel/preset-env@^7.14.7": - version "7.14.7" - resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.14.7.tgz#5c70b22d4c2d893b03d8c886a5c17422502b932a" - integrity sha512-itOGqCKLsSUl0Y+1nSfhbuuOlTs0MJk2Iv7iSH+XT/mR8U1zRLO7NjWlYXB47yhK4J/7j+HYty/EhFZDYKa/VA== - dependencies: - "@babel/compat-data" "^7.14.7" - "@babel/helper-compilation-targets" "^7.14.5" - "@babel/helper-plugin-utils" "^7.14.5" - "@babel/helper-validator-option" "^7.14.5" - "@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining" "^7.14.5" - "@babel/plugin-proposal-async-generator-functions" "^7.14.7" - "@babel/plugin-proposal-class-properties" "^7.14.5" - "@babel/plugin-proposal-class-static-block" "^7.14.5" - "@babel/plugin-proposal-dynamic-import" "^7.14.5" - "@babel/plugin-proposal-export-namespace-from" "^7.14.5" - "@babel/plugin-proposal-json-strings" "^7.14.5" - "@babel/plugin-proposal-logical-assignment-operators" "^7.14.5" - "@babel/plugin-proposal-nullish-coalescing-operator" "^7.14.5" - "@babel/plugin-proposal-numeric-separator" "^7.14.5" - "@babel/plugin-proposal-object-rest-spread" "^7.14.7" - "@babel/plugin-proposal-optional-catch-binding" "^7.14.5" - "@babel/plugin-proposal-optional-chaining" "^7.14.5" - "@babel/plugin-proposal-private-methods" "^7.14.5" - "@babel/plugin-proposal-private-property-in-object" "^7.14.5" - "@babel/plugin-proposal-unicode-property-regex" "^7.14.5" - "@babel/plugin-syntax-async-generators" "^7.8.4" - "@babel/plugin-syntax-class-properties" "^7.12.13" - "@babel/plugin-syntax-class-static-block" "^7.14.5" - "@babel/plugin-syntax-dynamic-import" "^7.8.3" - "@babel/plugin-syntax-export-namespace-from" "^7.8.3" - "@babel/plugin-syntax-json-strings" "^7.8.3" - "@babel/plugin-syntax-logical-assignment-operators" "^7.10.4" - "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" - "@babel/plugin-syntax-numeric-separator" "^7.10.4" - "@babel/plugin-syntax-object-rest-spread" "^7.8.3" - "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" - "@babel/plugin-syntax-optional-chaining" "^7.8.3" - "@babel/plugin-syntax-private-property-in-object" "^7.14.5" - "@babel/plugin-syntax-top-level-await" "^7.14.5" - "@babel/plugin-transform-arrow-functions" "^7.14.5" - "@babel/plugin-transform-async-to-generator" "^7.14.5" - "@babel/plugin-transform-block-scoped-functions" "^7.14.5" - "@babel/plugin-transform-block-scoping" "^7.14.5" - "@babel/plugin-transform-classes" "^7.14.5" - "@babel/plugin-transform-computed-properties" "^7.14.5" - "@babel/plugin-transform-destructuring" "^7.14.7" - "@babel/plugin-transform-dotall-regex" "^7.14.5" - "@babel/plugin-transform-duplicate-keys" "^7.14.5" - "@babel/plugin-transform-exponentiation-operator" "^7.14.5" - "@babel/plugin-transform-for-of" "^7.14.5" - "@babel/plugin-transform-function-name" "^7.14.5" - "@babel/plugin-transform-literals" "^7.14.5" - "@babel/plugin-transform-member-expression-literals" "^7.14.5" - "@babel/plugin-transform-modules-amd" "^7.14.5" - "@babel/plugin-transform-modules-commonjs" "^7.14.5" - "@babel/plugin-transform-modules-systemjs" "^7.14.5" - "@babel/plugin-transform-modules-umd" "^7.14.5" - "@babel/plugin-transform-named-capturing-groups-regex" "^7.14.7" - "@babel/plugin-transform-new-target" "^7.14.5" - "@babel/plugin-transform-object-super" "^7.14.5" - "@babel/plugin-transform-parameters" "^7.14.5" - "@babel/plugin-transform-property-literals" "^7.14.5" - "@babel/plugin-transform-regenerator" "^7.14.5" - "@babel/plugin-transform-reserved-words" "^7.14.5" - "@babel/plugin-transform-shorthand-properties" "^7.14.5" - "@babel/plugin-transform-spread" "^7.14.6" - "@babel/plugin-transform-sticky-regex" "^7.14.5" - "@babel/plugin-transform-template-literals" "^7.14.5" - "@babel/plugin-transform-typeof-symbol" "^7.14.5" - "@babel/plugin-transform-unicode-escapes" "^7.14.5" - "@babel/plugin-transform-unicode-regex" "^7.14.5" - "@babel/preset-modules" "^0.1.4" - "@babel/types" "^7.14.5" - babel-plugin-polyfill-corejs2 "^0.2.2" - babel-plugin-polyfill-corejs3 "^0.2.2" - babel-plugin-polyfill-regenerator "^0.2.2" - core-js-compat "^3.15.0" - semver "^6.3.0" - -"@babel/preset-modules@^0.1.4": - version "0.1.4" - resolved "https://registry.yarnpkg.com/@babel/preset-modules/-/preset-modules-0.1.4.tgz#362f2b68c662842970fdb5e254ffc8fc1c2e415e" - integrity sha512-J36NhwnfdzpmH41M1DrnkkgAqhZaqr/NBdPfQ677mLzlaXo+oDiv1deyCDtgAhz8p328otdob0Du7+xgHGZbKg== - dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-proposal-unicode-property-regex" "^7.4.4" - "@babel/plugin-transform-dotall-regex" "^7.4.4" - "@babel/types" "^7.4.4" - esutils "^2.0.2" - -"@babel/runtime@^7.8.4": - version "7.14.6" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.14.6.tgz#535203bc0892efc7dec60bdc27b2ecf6e409062d" - integrity sha512-/PCB2uJ7oM44tz8YhC4Z/6PeOKXp4K588f+5M3clr1M4zbqztlo0XEfJ2LEzj/FgwfgGcIdl8n7YYjTCI0BYwg== - dependencies: - regenerator-runtime "^0.13.4" - "@babel/template@^7.12.13", "@babel/template@^7.3.3": version "7.12.13" resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.12.13.tgz#530265be8a2589dbb37523844c5bcb55947fb327" @@ -1116,15 +396,6 @@ "@babel/parser" "^7.12.13" "@babel/types" "^7.12.13" -"@babel/template@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.14.5.tgz#a9bc9d8b33354ff6e55a9c60d1109200a68974f4" - integrity sha512-6Z3Po85sfxRGachLULUhOmvAaOo7xCvqGQtxINai2mEGPFm6pQ4z5QInFnUrRpfoSV60BnjyF5F3c+15fxFV1g== - dependencies: - "@babel/code-frame" "^7.14.5" - "@babel/parser" "^7.14.5" - "@babel/types" "^7.14.5" - "@babel/traverse@^7.1.0", "@babel/traverse@^7.13.0", "@babel/traverse@^7.13.13", "@babel/traverse@^7.13.15": version "7.13.15" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.13.15.tgz#c38bf7679334ddd4028e8e1f7b3aa5019f0dada7" @@ -1153,21 +424,6 @@ debug "^4.1.0" globals "^11.1.0" -"@babel/traverse@^7.14.5": - version "7.14.7" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.14.7.tgz#64007c9774cfdc3abd23b0780bc18a3ce3631753" - integrity sha512-9vDr5NzHu27wgwejuKL7kIOm4bwEtaPQ4Z6cpCmjSuaRqpH/7xc4qcGEscwMqlkwgcXl6MvqoAjZkQ24uSdIZQ== - dependencies: - "@babel/code-frame" "^7.14.5" - "@babel/generator" "^7.14.5" - "@babel/helper-function-name" "^7.14.5" - "@babel/helper-hoist-variables" "^7.14.5" - "@babel/helper-split-export-declaration" "^7.14.5" - "@babel/parser" "^7.14.7" - "@babel/types" "^7.14.5" - debug "^4.1.0" - globals "^11.1.0" - "@babel/traverse@^7.7.2": version "7.14.0" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.14.0.tgz#cea0dc8ae7e2b1dec65f512f39f3483e8cc95aef" @@ -1207,14 +463,6 @@ "@babel/helper-validator-identifier" "^7.14.0" to-fast-properties "^2.0.0" -"@babel/types@^7.14.5", "@babel/types@^7.4.4": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.14.5.tgz#3bb997ba829a2104cedb20689c4a5b8121d383ff" - integrity sha512-M/NzBpEL95I5Hh4dwhin5JlE7EzO5PHMAuzjxss3tiOBD46KfQvVedN/3jEPZvdRvtsK2222XfdHogNIttFgcg== - dependencies: - "@babel/helper-validator-identifier" "^7.14.5" - to-fast-properties "^2.0.0" - "@bcoe/v8-coverage@^0.2.3": version "0.2.3" resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" @@ -2014,6 +1262,13 @@ abort-controller@^3.0.0: dependencies: event-target-shim "^5.0.0" +abstract-leveldown@~0.12.0, abstract-leveldown@~0.12.1: + version "0.12.4" + resolved "https://registry.yarnpkg.com/abstract-leveldown/-/abstract-leveldown-0.12.4.tgz#29e18e632e60e4e221d5810247852a63d7b2e410" + integrity sha1-KeGOYy5g5OIh1YECR4UqY9ey5BA= + dependencies: + xtend "~3.0.0" + acorn-globals@^4.3.0: version "4.3.2" resolved "https://registry.yarnpkg.com/acorn-globals/-/acorn-globals-4.3.2.tgz#4e2c2313a597fd589720395f6354b41cd5ec8006" @@ -2054,11 +1309,6 @@ acorn-walk@^7.0.0, acorn-walk@^7.1.1: resolved "https://registry.yarnpkg.com/acorn-walk/-/acorn-walk-7.2.0.tgz#0de889a601203909b0fbe07b8938dc21d2e967bc" integrity sha512-OPdCF6GsMIP+Az+aWfAAOEt2/+iVDKE7oy6lJ098aoe59oAmK76qV6Gw60SbZ8jHuG2wH058GF4pLFbYamYrVA== -acorn@^5.7.3: - version "5.7.4" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.4.tgz#3e8d8a9947d0599a1796d10225d7432f4a4acf5e" - integrity sha512-1D++VG7BhrtvQpNbBzovKNc1FLGGEE/oGe7b9xJm/RFHMBeUaUGpluV9RLjZa47YFdPcDAenEYuq9pQPcMdLJg== - acorn@^6.0.1, acorn@^6.0.2: version "6.4.2" resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.4.2.tgz#35866fd710528e92de10cf06016498e47e39e1e6" @@ -2374,13 +1624,6 @@ babel-jest@^27.0.2: graceful-fs "^4.2.4" slash "^3.0.0" -babel-plugin-dynamic-import-node@^2.3.3: - version "2.3.3" - resolved "https://registry.yarnpkg.com/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.3.tgz#84fda19c976ec5c6defef57f9427b3def66e17a3" - integrity sha512-jZVI+s9Zg3IqA/kdi0i6UDCybUI3aSBLnglhYbSSjKlV7yF1F/5LWv8MakQmvYpnbJDS6fcBL2KzHSxNCMtWSQ== - dependencies: - object.assign "^4.1.0" - babel-plugin-istanbul@^6.0.0: version "6.0.0" resolved "https://registry.yarnpkg.com/babel-plugin-istanbul/-/babel-plugin-istanbul-6.0.0.tgz#e159ccdc9af95e0b570c75b4573b7c34d671d765" @@ -2402,30 +1645,6 @@ babel-plugin-jest-hoist@^27.0.1: "@types/babel__core" "^7.0.0" "@types/babel__traverse" "^7.0.6" -babel-plugin-polyfill-corejs2@^0.2.2: - version "0.2.2" - resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-corejs2/-/babel-plugin-polyfill-corejs2-0.2.2.tgz#e9124785e6fd94f94b618a7954e5693053bf5327" - integrity sha512-kISrENsJ0z5dNPq5eRvcctITNHYXWOA4DUZRFYCz3jYCcvTb/A546LIddmoGNMVYg2U38OyFeNosQwI9ENTqIQ== - dependencies: - "@babel/compat-data" "^7.13.11" - "@babel/helper-define-polyfill-provider" "^0.2.2" - semver "^6.1.1" - -babel-plugin-polyfill-corejs3@^0.2.2: - version "0.2.3" - resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.2.3.tgz#72add68cf08a8bf139ba6e6dfc0b1d504098e57b" - integrity sha512-rCOFzEIJpJEAU14XCcV/erIf/wZQMmMT5l5vXOpL5uoznyOGfDIjPj6FVytMvtzaKSTSVKouOCTPJ5OMUZH30g== - dependencies: - "@babel/helper-define-polyfill-provider" "^0.2.2" - core-js-compat "^3.14.0" - -babel-plugin-polyfill-regenerator@^0.2.2: - version "0.2.2" - resolved "https://registry.yarnpkg.com/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.2.2.tgz#b310c8d642acada348c1fa3b3e6ce0e851bee077" - integrity sha512-Goy5ghsc21HgPDFtzRkSirpZVW35meGoTmTOb2bxqdl60ghub4xOidgNTHaZfQ2FaxQsKmwvXtOAkcIS4SMBWg== - dependencies: - "@babel/helper-define-polyfill-provider" "^0.2.2" - babel-preset-current-node-syntax@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.0.1.tgz#b4399239b89b2a011f9ddbe3e4f401fc40cff73b" @@ -2452,11 +1671,6 @@ babel-preset-jest@^27.0.1: babel-plugin-jest-hoist "^27.0.1" babel-preset-current-node-syntax "^1.0.0" -babelify@^10.0.0: - version "10.0.0" - resolved "https://registry.yarnpkg.com/babelify/-/babelify-10.0.0.tgz#fe73b1a22583f06680d8d072e25a1e0d1d1d7fb5" - integrity sha512-X40FaxyH7t3X+JFAKvb1H9wooWKLRCi8pg3m8poqtdZaIng+bjzp9RvKQCvRjF9isHiPkXspbbXT/zwXLtwgwg== - balanced-match@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" @@ -2509,6 +1723,13 @@ bl@^4.0.3: inherits "^2.0.4" readable-stream "^3.4.0" +bl@~0.8.1: + version "0.8.2" + resolved "https://registry.yarnpkg.com/bl/-/bl-0.8.2.tgz#c9b6bca08d1bc2ea00fc8afb4f1a5fd1e1c66e4e" + integrity sha1-yba8oI0bwuoA/Ir7Txpf0eHGbk4= + dependencies: + readable-stream "~1.0.26" + bn.js@^4.0.0, bn.js@^4.1.0, bn.js@^4.1.1, bn.js@^4.11.9: version "4.12.0" resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.12.0.tgz#775b3f278efbb9718eec7361f483fb36fbbfea88" @@ -2561,6 +1782,16 @@ braces@^3.0.1: dependencies: fill-range "^7.0.1" +brfs@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/brfs/-/brfs-2.0.2.tgz#44237878fa82aa479ce4f5fe2c1796ec69f07845" + integrity sha512-IrFjVtwu4eTJZyu8w/V2gxU7iLTtcHih67sgEdzrhjLBMHp2uYefUBfdM4k2UvcuWMgV7PQDZHSLeNWnLFKWVQ== + dependencies: + quote-stream "^1.0.1" + resolve "^1.1.5" + static-module "^3.0.2" + through2 "^2.0.0" + brorand@^1.0.1, brorand@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/brorand/-/brorand-1.1.0.tgz#12c25efe40a45e3c323eb8675a0a0ce57b22371f" @@ -2640,6 +1871,15 @@ browserify-des@^1.0.0: inherits "^2.0.1" safe-buffer "^5.1.2" +browserify-fs@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/browserify-fs/-/browserify-fs-1.0.0.tgz#f075aa8a729d4d1716d066620e386fcc1311a96f" + integrity sha1-8HWqinKdTRcW0GZiDjhvzBMRqW8= + dependencies: + level-filesystem "^1.0.1" + level-js "^2.1.3" + levelup "^0.18.2" + browserify-package-json@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/browserify-package-json/-/browserify-package-json-1.0.1.tgz#98dde8aa5c561fd6d3fe49bbaa102b74b396fdea" @@ -2779,7 +2019,7 @@ buffer-equal@0.0.1: resolved "https://registry.yarnpkg.com/buffer-equal/-/buffer-equal-0.0.1.tgz#91bc74b11ea405bc916bc6aa908faafa5b4aac4b" integrity sha1-kbx0sR6kBbyRa8aqkI+q+ltKrEs= -buffer-es6@^4.9.3: +buffer-es6@^4.9.2: version "4.9.3" resolved "https://registry.yarnpkg.com/buffer-es6/-/buffer-es6-4.9.3.tgz#f26347b82df76fd37e18bcb5288c4970cfd5c404" integrity sha1-8mNHuC33b9N+GLy1KIxJcM/VxAQ= @@ -3144,6 +2384,11 @@ clone@^1.0.2: resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.4.tgz#da309cc263df15994c688ca902179ca3c7cd7c7e" integrity sha1-2jCcwmPfFZlMaIypAheco8fNfH4= +clone@~0.1.9: + version "0.1.19" + resolved "https://registry.yarnpkg.com/clone/-/clone-0.1.19.tgz#613fb68639b26a494ac53253e15b1a6bd88ada85" + integrity sha1-YT+2hjmyaklKxTJT4Vsaa9iK2oU= + co@^4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" @@ -3253,7 +2498,7 @@ concat-map@0.0.1: resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= -concat-stream@^1.6.0, concat-stream@^1.6.1, concat-stream@~1.6.0: +concat-stream@^1.4.4, concat-stream@^1.6.0, concat-stream@^1.6.1, concat-stream@~1.6.0: version "1.6.2" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" integrity sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw== @@ -3457,14 +2702,6 @@ copy-descriptor@^0.1.0: resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= -core-js-compat@^3.14.0, core-js-compat@^3.15.0: - version "3.15.2" - resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.15.2.tgz#47272fbb479880de14b4e6081f71f3492f5bd3cb" - integrity sha512-Wp+BJVvwopjI+A1EFqm2dwUmWYXrvucmtIB2LgXn/Rb+gWPKYxtmb4GKHGKG/KGF1eK9jfjzT38DITbTOCX/SQ== - dependencies: - browserslist "^4.16.6" - semver "7.0.0" - core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" @@ -3563,7 +2800,7 @@ cross-spawn@^7.0.0, cross-spawn@^7.0.1, cross-spawn@^7.0.2, cross-spawn@^7.0.3: shebang-command "^2.0.0" which "^2.0.1" -crypto-browserify@^3.0.0: +crypto-browserify@^3.0.0, crypto-browserify@^3.11.0: version "3.12.0" resolved "https://registry.yarnpkg.com/crypto-browserify/-/crypto-browserify-3.12.0.tgz#396cf9f3137f03e4b8e532c58f698254e00f80ec" integrity sha512-fz4spIh+znjO2VjL+IdhEpRJ3YN6sMzITSBijk6FK2UvTqruSQW+/cCZTSNsMiZNvUeq0CqurF+dAbyiGOY6Wg== @@ -3774,6 +3011,13 @@ defer-to-connect@^1.0.1: resolved "https://registry.yarnpkg.com/defer-to-connect/-/defer-to-connect-1.1.3.tgz#331ae050c08dcf789f8c83a7b81f0ed94f4ac591" integrity sha512-0ISdNousHvZT2EiFlZeZAHBUvSxmKswVCEf8hW7KWgG4a8MVEu/3Vb6uWYozkjylyCxe0JBIiRB1jV45S70WVQ== +deferred-leveldown@~0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/deferred-leveldown/-/deferred-leveldown-0.2.0.tgz#2cef1f111e1c57870d8bbb8af2650e587cd2f5b4" + integrity sha1-LO8fER4cV4cNi7uK8mUOWHzS9bQ= + dependencies: + abstract-leveldown "~0.12.1" + define-properties@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" @@ -4010,6 +3254,13 @@ enquirer@^2.3.5, enquirer@^2.3.6: dependencies: ansi-colors "^4.1.1" +errno@^0.1.1, errno@~0.1.1: + version "0.1.8" + resolved "https://registry.yarnpkg.com/errno/-/errno-0.1.8.tgz#8bb3e9c7d463be4976ff888f76b4809ebc2e811f" + integrity sha512-dJ6oBr5SQ1VSd9qkk7ByRgb/1SH4JZjCHSW/mr63/QcXO9zLVxvJ6Oy13nio03rxpSnVDDjFor75SjVeZWPW/A== + dependencies: + prr "~1.0.1" + error-ex@^1.2.0, error-ex@^1.3.1: version "1.3.2" resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" @@ -4272,11 +3523,6 @@ estree-is-function@^1.0.0: resolved "https://registry.yarnpkg.com/estree-is-function/-/estree-is-function-1.0.0.tgz#c0adc29806d7f18a74db7df0f3b2666702e37ad2" integrity sha512-nSCWn1jkSq2QAtkaVLJZY2ezwcFO161HVc174zL1KPW3RJ+O6C3eJb8Nx7OXzvhoEv+nLgSR1g71oWUHUDTrJA== -estree-walker@^0.5.2: - version "0.5.2" - resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-0.5.2.tgz#d3850be7529c9580d815600b53126515e146dd39" - integrity sha512-XpCnW/AE10ws/kDAs37cngSkvgIR8aN3G0MS85m7dUpuK2EREo9VJ00uvw6Dg/hXEpfsE1I1TvJOJr+Z+TL+ig== - estree-walker@^0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-0.6.1.tgz#53049143f40c6eb918b23671d1fe3219f3a1b362" @@ -4619,7 +3865,7 @@ for-in@^1.0.2: resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" integrity sha1-gQaNKVqBQuwKxybG4iAMMPttXoA= -foreach@^2.0.5: +foreach@^2.0.5, foreach@~2.0.1: version "2.0.5" resolved "https://registry.yarnpkg.com/foreach/-/foreach-2.0.5.tgz#0bee005018aeb260d0a3af3ae658dd0136ec1b99" integrity sha1-C+4AUBiusmDQo6865ljdATbsG5k= @@ -4704,6 +3950,13 @@ furi@^2.0.0: "@types/is-windows" "^1.0.0" is-windows "^1.0.2" +fwd-stream@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/fwd-stream/-/fwd-stream-1.0.4.tgz#ed281cabed46feecf921ee32dc4c50b372ac7cfa" + integrity sha1-7Sgcq+1G/uz5Ie4y3ExQs3KsfPo= + dependencies: + readable-stream "~1.0.26-4" + gensync@^1.0.0-beta.2: version "1.0.0-beta.2" resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" @@ -5160,6 +4413,11 @@ idb-keyval@2.2.0: resolved "https://registry.yarnpkg.com/idb-keyval/-/idb-keyval-2.2.0.tgz#b28020d53e3cf1621e3ec605e57e5305f37b195e" integrity sha1-soAg1T488WIePsYF5X5TBfN7GV4= +idb-wrapper@^1.5.0: + version "1.7.2" + resolved "https://registry.yarnpkg.com/idb-wrapper/-/idb-wrapper-1.7.2.tgz#8251afd5e77fe95568b1c16152eb44b396767ea2" + integrity sha512-zfNREywMuf0NzDo9mVsL0yegjsirJxHpKHvWcyRozIqQy89g0a3U+oBPOCN4cc0oCiOuYgZHimzaW/R46G1Mpg== + ieee754@^1.1.13: version "1.2.1" resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" @@ -5236,6 +4494,11 @@ indent-string@^4.0.0: resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-4.0.0.tgz#624f8f4497d619b2d9768531d58f4122854d7251" integrity sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg== +indexof@~0.0.1: + version "0.0.1" + resolved "https://registry.yarnpkg.com/indexof/-/indexof-0.0.1.tgz#82dc336d232b9062179d05ab3293a66059fd435d" + integrity sha1-gtwzbSMrkGIXnQWrMpOmYFn9Q10= + inflight@^1.0.4: version "1.0.6" resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" @@ -5552,6 +4815,11 @@ is-obj@^2.0.0: resolved "https://registry.yarnpkg.com/is-obj/-/is-obj-2.0.0.tgz#473fb05d973705e3fd9620545018ca8e22ef4982" integrity sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w== +is-object@~0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/is-object/-/is-object-0.1.2.tgz#00efbc08816c33cfc4ac8251d132e10dc65098d7" + integrity sha1-AO+8CIFsM8/ErIJR0TLhDcZQmNc= + is-odd@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-odd/-/is-odd-2.0.0.tgz#7646624671fd7ea558ccd9a2795182f2958f1b24" @@ -5673,6 +4941,16 @@ is-yarn-global@^0.3.0: resolved "https://registry.yarnpkg.com/is-yarn-global/-/is-yarn-global-0.3.0.tgz#d502d3382590ea3004893746754c89139973e232" integrity sha512-VjSeb/lHmkoyd8ryPVIKvOCn4D1koMqY+vqyjjUfc3xyKtP4dYOxM44sZrnqQSzSds3xyOrUTLTC9LVCVgLngw== +is@~0.2.6: + version "0.2.7" + resolved "https://registry.yarnpkg.com/is/-/is-0.2.7.tgz#3b34a2c48f359972f35042849193ae7264b63562" + integrity sha1-OzSixI81mXLzUEKEkZOucmS2NWI= + +isarray@0.0.1: + version "0.0.1" + resolved "https://registry.yarnpkg.com/isarray/-/isarray-0.0.1.tgz#8a18acfca9a8f4177e09abfc6038939b05d1eedf" + integrity sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8= + isarray@1.0.0, isarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" @@ -5683,6 +4961,11 @@ isarray@^2.0.4: resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.4.tgz#38e7bcbb0f3ba1b7933c86ba1894ddfc3781bbb7" integrity sha512-GMxXOiUirWg1xTKRipM0Ek07rX+ubx4nNVElTJdNLYmNO/2YrDkgJGw9CljXn+r4EWiDQg/8lsRdHyg2PJuUaA== +isbuffer@~0.0.0: + version "0.0.0" + resolved "https://registry.yarnpkg.com/isbuffer/-/isbuffer-0.0.0.tgz#38c146d9df528b8bf9b0701c3d43cf12df3fc39b" + integrity sha1-OMFG2d9Si4v5sHAcPUPPEt8/w5s= + isexe@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" @@ -6150,6 +5433,15 @@ jest-watcher@^27.0.2: jest-util "^27.0.2" string-length "^4.0.1" +jest-worker@^26.2.1: + version "26.6.2" + resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-26.6.2.tgz#7f72cbc4d643c365e27b9fd775f9d0eaa9c7a8ed" + integrity sha512-KWYVV1c4i+jbMpaBC+U++4Va0cp8OisU185o73T1vo99hqi7w8tSJfUXYswwqqrjzwxa6KpRK54WhPvwf5w6PQ== + dependencies: + "@types/node" "*" + merge-stream "^2.0.0" + supports-color "^7.0.0" + jest-worker@^27.0.2: version "27.0.2" resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-27.0.2.tgz#4ebeb56cef48b3e7514552f80d0d80c0129f0b05" @@ -6265,11 +5557,6 @@ jsesc@^2.5.1: resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== -jsesc@~0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-0.5.0.tgz#e7dee66e35d6fc16f710fe91d5cf69f70f08911d" - integrity sha1-597mbjXW/Bb3EP6R1c9p9w8IkR0= - json-buffer@3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/json-buffer/-/json-buffer-3.0.0.tgz#5b1f397afc75d677bde8bcfc0e47e1f9a3d9a898" @@ -6424,6 +5711,91 @@ lazystream@^1.0.0: dependencies: readable-stream "^2.0.5" +level-blobs@^0.1.7: + version "0.1.7" + resolved "https://registry.yarnpkg.com/level-blobs/-/level-blobs-0.1.7.tgz#9ab9b97bb99f1edbf9f78a3433e21ed56386bdaf" + integrity sha1-mrm5e7mfHtv594o0M+Ie1WOGva8= + dependencies: + level-peek "1.0.6" + once "^1.3.0" + readable-stream "^1.0.26-4" + +level-filesystem@^1.0.1: + version "1.2.0" + resolved "https://registry.yarnpkg.com/level-filesystem/-/level-filesystem-1.2.0.tgz#a00aca9919c4a4dfafdca6a8108d225aadff63b3" + integrity sha1-oArKmRnEpN+v3KaoEI0iWq3/Y7M= + dependencies: + concat-stream "^1.4.4" + errno "^0.1.1" + fwd-stream "^1.0.4" + level-blobs "^0.1.7" + level-peek "^1.0.6" + level-sublevel "^5.2.0" + octal "^1.0.0" + once "^1.3.0" + xtend "^2.2.0" + +level-fix-range@2.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/level-fix-range/-/level-fix-range-2.0.0.tgz#c417d62159442151a19d9a2367868f1724c2d548" + integrity sha1-xBfWIVlEIVGhnZojZ4aPFyTC1Ug= + dependencies: + clone "~0.1.9" + +level-fix-range@~1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/level-fix-range/-/level-fix-range-1.0.2.tgz#bf15b915ae36d8470c821e883ddf79cd16420828" + integrity sha1-vxW5Fa422EcMgh6IPd95zRZCCCg= + +"level-hooks@>=4.4.0 <5": + version "4.5.0" + resolved "https://registry.yarnpkg.com/level-hooks/-/level-hooks-4.5.0.tgz#1b9ae61922930f3305d1a61fc4d83c8102c0dd93" + integrity sha1-G5rmGSKTDzMF0aYfxNg8gQLA3ZM= + dependencies: + string-range "~1.2" + +level-js@^2.1.3: + version "2.2.4" + resolved "https://registry.yarnpkg.com/level-js/-/level-js-2.2.4.tgz#bc055f4180635d4489b561c9486fa370e8c11697" + integrity sha1-vAVfQYBjXUSJtWHJSG+jcOjBFpc= + dependencies: + abstract-leveldown "~0.12.0" + idb-wrapper "^1.5.0" + isbuffer "~0.0.0" + ltgt "^2.1.2" + typedarray-to-buffer "~1.0.0" + xtend "~2.1.2" + +level-peek@1.0.6, level-peek@^1.0.6: + version "1.0.6" + resolved "https://registry.yarnpkg.com/level-peek/-/level-peek-1.0.6.tgz#bec51c72a82ee464d336434c7c876c3fcbcce77f" + integrity sha1-vsUccqgu5GTTNkNMfIdsP8vM538= + dependencies: + level-fix-range "~1.0.2" + +level-sublevel@^5.2.0: + version "5.2.3" + resolved "https://registry.yarnpkg.com/level-sublevel/-/level-sublevel-5.2.3.tgz#744c12c72d2e72be78dde3b9b5cd84d62191413a" + integrity sha1-dEwSxy0ucr543eO5tc2E1iGRQTo= + dependencies: + level-fix-range "2.0" + level-hooks ">=4.4.0 <5" + string-range "~1.2.1" + xtend "~2.0.4" + +levelup@^0.18.2: + version "0.18.6" + resolved "https://registry.yarnpkg.com/levelup/-/levelup-0.18.6.tgz#e6a01cb089616c8ecc0291c2a9bd3f0c44e3e5eb" + integrity sha1-5qAcsIlhbI7MApHCqb0/DETj5es= + dependencies: + bl "~0.8.1" + deferred-leveldown "~0.2.0" + errno "~0.1.1" + prr "~0.0.0" + readable-stream "~1.0.26" + semver "~2.3.1" + xtend "~3.0.0" + leven@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/leven/-/leven-3.1.0.tgz#77891de834064cccba82ae7842bb6b14a13ed7f2" @@ -6521,11 +5893,6 @@ lodash.clonedeep@^4.5.0: resolved "https://registry.yarnpkg.com/lodash.clonedeep/-/lodash.clonedeep-4.5.0.tgz#e23f3f9c4f8fbdde872529c1071857a086e5ccef" integrity sha1-4j8/nE+Pvd6HJSnBBxhXoIblzO8= -lodash.debounce@^4.0.8: - version "4.0.8" - resolved "https://registry.yarnpkg.com/lodash.debounce/-/lodash.debounce-4.0.8.tgz#82d79bff30a67c4005ffd5e2515300ad9ca4d7af" - integrity sha1-gteb/zCmfEAF/9XiUVMArZyk168= - lodash.defaults@^4.2.0: version "4.2.0" resolved "https://registry.yarnpkg.com/lodash.defaults/-/lodash.defaults-4.2.0.tgz#d09178716ffea4dde9e5fb7b37f6f0802274580c" @@ -6648,6 +6015,11 @@ lsmod@1.0.0: resolved "https://registry.yarnpkg.com/lsmod/-/lsmod-1.0.0.tgz#9a00f76dca36eb23fa05350afe1b585d4299e64b" integrity sha1-mgD3bco26yP6BTUK/htYXUKZ5ks= +ltgt@^2.1.2: + version "2.2.1" + resolved "https://registry.yarnpkg.com/ltgt/-/ltgt-2.2.1.tgz#f35ca91c493f7b73da0e07495304f17b31f87ee5" + integrity sha1-81ypHEk/e3PaDgdJUwTxezH4fuU= + magic-string@0.25.1: version "0.25.1" resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.25.1.tgz#b1c248b399cd7485da0fe7385c2fc7011843266e" @@ -6655,13 +6027,6 @@ magic-string@0.25.1: dependencies: sourcemap-codec "^1.4.1" -magic-string@^0.22.5: - version "0.22.5" - resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.22.5.tgz#8e9cf5afddf44385c1da5bc2a6a0dbd10b03657e" - integrity sha512-oreip9rJZkzvA8Qzk9HFs8fZGF/u7H/gtrE8EN6RjKJ9kh2HlC+yQ2QezifqTZfGyiuAV0dRv5a+y/8gBb1m9w== - dependencies: - vlq "^0.2.2" - magic-string@^0.25.2, magic-string@^0.25.3, magic-string@^0.25.7: version "0.25.7" resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.25.7.tgz#3f497d6fd34c669c6798dcb821f2ef31f5445051" @@ -7109,6 +6474,20 @@ object-keys@^1.0.12, object-keys@^1.1.1: resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.1.tgz#1c47f272df277f3b1daf061677d9c82e2322c60e" integrity sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA== +object-keys@~0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-0.2.0.tgz#cddec02998b091be42bf1035ae32e49f1cb6ea67" + integrity sha1-zd7AKZiwkb5CvxA1rjLknxy26mc= + dependencies: + foreach "~2.0.1" + indexof "~0.0.1" + is "~0.2.6" + +object-keys@~0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-0.4.0.tgz#28a6aae7428dd2c3a92f3d95f21335dd204e0336" + integrity sha1-KKaq50KN0sOpLz2V8hM13SBOAzY= + object-visit@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/object-visit/-/object-visit-1.0.1.tgz#f79c4493af0c5377b59fe39d395e41042dd045bb" @@ -7116,7 +6495,7 @@ object-visit@^1.0.0: dependencies: isobject "^3.0.0" -object.assign@^4.1.0, object.assign@^4.1.2: +object.assign@^4.1.2: version "4.1.2" resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.2.tgz#0ed54a342eceb37b38ff76eb831a0e788cb63940" integrity sha512-ixT2L5THXsApyiUPYKmW+2EHpXXe5Ii3M+f4e+aJFAHao5amFRW6J0OO6c/LU8Be47utCx2GL89hxGB6XSmKuQ== @@ -7133,6 +6512,11 @@ object.pick@^1.3.0: dependencies: isobject "^3.0.1" +octal@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/octal/-/octal-1.0.0.tgz#63e7162a68efbeb9e213588d58e989d1e5c4530b" + integrity sha1-Y+cWKmjvvrniE1iNWOmJ0eXEUws= + offset-sourcemap-lines@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/offset-sourcemap-lines/-/offset-sourcemap-lines-1.0.1.tgz#5854dff74b73fc06efcb61d7b721a8113d99be92" @@ -7599,7 +6983,7 @@ pretty-json-stringify@^0.0.2: resolved "https://registry.yarnpkg.com/pretty-json-stringify/-/pretty-json-stringify-0.0.2.tgz#dc0f1dbeab6bc1ab15f40d4cce4f38b75b17a334" integrity sha1-3A8dvqtrwasV9A1Mzk84t1sXozQ= -process-es6@^0.11.6: +process-es6@^0.11.2: version "0.11.6" resolved "https://registry.yarnpkg.com/process-es6/-/process-es6-0.11.6.tgz#c6bb389f9a951f82bd4eb169600105bd2ff9c778" integrity sha1-xrs4n5qVH4K9TrFpYAEFvS/5x3g= @@ -7632,6 +7016,16 @@ proxy-from-env@^1.1.0: resolved "https://registry.yarnpkg.com/proxy-from-env/-/proxy-from-env-1.1.0.tgz#e102f16ca355424865755d2c9e8ea4f24d58c3e2" integrity sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg== +prr@~0.0.0: + version "0.0.0" + resolved "https://registry.yarnpkg.com/prr/-/prr-0.0.0.tgz#1a84b85908325501411853d0081ee3fa86e2926a" + integrity sha1-GoS4WQgyVQFBGFPQCB7j+obikmo= + +prr@~1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/prr/-/prr-1.0.1.tgz#d3fc114ba06995a45ec6893f484ceb1d78f5f476" + integrity sha1-0/wRS6BplaRexok/SEzrHXj19HY= + ps-list@^7.2.0: version "7.2.0" resolved "https://registry.yarnpkg.com/ps-list/-/ps-list-7.2.0.tgz#3d110e1de8249a4b178c9b1cf2a215d1e4e42fc0" @@ -7739,7 +7133,7 @@ quote-stream@^1.0.1: minimist "^1.1.3" through2 "^2.0.0" -randombytes@^2.0.0, randombytes@^2.0.1, randombytes@^2.0.5: +randombytes@^2.0.0, randombytes@^2.0.1, randombytes@^2.0.5, randombytes@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a" integrity sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ== @@ -7844,6 +7238,16 @@ read-pkg@^5.2.0: string_decoder "^1.1.1" util-deprecate "^1.0.1" +readable-stream@^1.0.26-4: + version "1.1.14" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.1.14.tgz#7cf4c54ef648e3813084c636dd2079e166c081d9" + integrity sha1-fPTFTvZI44EwhMY23SB54WbAgdk= + dependencies: + core-util-is "~1.0.0" + inherits "~2.0.1" + isarray "0.0.1" + string_decoder "~0.10.x" + readable-stream@^2.0.0, readable-stream@^2.0.2, readable-stream@^2.0.5, readable-stream@^2.2.2, readable-stream@^2.3.0, readable-stream@^2.3.5, readable-stream@~2.3.3, readable-stream@~2.3.6: version "2.3.7" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.7.tgz#1eca1cf711aef814c04f62252a36a62f6cb23b57" @@ -7857,6 +7261,16 @@ readable-stream@^2.0.0, readable-stream@^2.0.2, readable-stream@^2.0.5, readable string_decoder "~1.1.1" util-deprecate "~1.0.1" +readable-stream@~1.0.26, readable-stream@~1.0.26-4: + version "1.0.34" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.0.34.tgz#125820e34bc842d2f2aaafafe4c2916ee32c157c" + integrity sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw= + dependencies: + core-util-is "~1.0.0" + inherits "~2.0.1" + isarray "0.0.1" + string_decoder "~0.10.x" + rechoir@^0.6.2: version "0.6.2" resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.6.2.tgz#85204b54dba82d5742e28c96756ef43af50e3384" @@ -7872,30 +7286,6 @@ redent@^1.0.0: indent-string "^2.1.0" strip-indent "^1.0.1" -regenerate-unicode-properties@^8.2.0: - version "8.2.0" - resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-8.2.0.tgz#e5de7111d655e7ba60c057dbe9ff37c87e65cdec" - integrity sha512-F9DjY1vKLo/tPePDycuH3dn9H1OTPIkVD9Kz4LODu+F2C75mgjAJ7x/gwy6ZcSNRAAkhNlJSOHRe8k3p+K9WhA== - dependencies: - regenerate "^1.4.0" - -regenerate@^1.4.0: - version "1.4.2" - resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.4.2.tgz#b9346d8827e8f5a32f7ba29637d398b69014848a" - integrity sha512-zrceR/XhGYU/d/opr2EKO7aRHUeiBI8qjtfHqADTwZd6Szfy16la6kqD0MIUs5z5hx6AaKa+PixpPrR289+I0A== - -regenerator-runtime@^0.13.4: - version "0.13.7" - resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.7.tgz#cac2dacc8a1ea675feaabaeb8ae833898ae46f55" - integrity sha512-a54FxoJDIr27pgf7IgeQGxmqUNYrcV338lf/6gH456HZ/PhX+5BcwHXG9ajESmwe6WRO0tAzRUrRmNONWgkrew== - -regenerator-transform@^0.14.2: - version "0.14.5" - resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.14.5.tgz#c98da154683671c9c4dcb16ece736517e1b7feb4" - integrity sha512-eOf6vka5IO151Jfsw2NO9WpGX58W6wWmefK3I1zEGr0lOD0u8rwPaNqQL1aRxUaxLeKO3ArNh3VYg1KbaD+FFw== - dependencies: - "@babel/runtime" "^7.8.4" - regex-not@^1.0.0, regex-not@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/regex-not/-/regex-not-1.0.2.tgz#1f4ece27e00b0b65e0247a6810e6a85d83a5752c" @@ -7909,18 +7299,6 @@ regexpp@^3.1.0: resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-3.1.0.tgz#206d0ad0a5648cffbdb8ae46438f3dc51c9f78e2" integrity sha512-ZOIzd8yVsQQA7j8GCSlPGXwg5PfmA1mrq0JP4nGhh54LaKN3xdai/vHUDu74pKwV8OxseMS65u2NImosQcSD0Q== -regexpu-core@^4.7.1: - version "4.7.1" - resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-4.7.1.tgz#2dea5a9a07233298fbf0db91fa9abc4c6e0f8ad6" - integrity sha512-ywH2VUraA44DZQuRKzARmw6S66mr48pQVva4LBeRhcOltJ6hExvWly5ZjFLYo67xbIxb6W1q4bAGtgfEl20zfQ== - dependencies: - regenerate "^1.4.0" - regenerate-unicode-properties "^8.2.0" - regjsgen "^0.5.1" - regjsparser "^0.6.4" - unicode-match-property-ecmascript "^1.0.4" - unicode-match-property-value-ecmascript "^1.2.0" - registry-auth-token@^4.0.0: version "4.2.0" resolved "https://registry.yarnpkg.com/registry-auth-token/-/registry-auth-token-4.2.0.tgz#1d37dffda72bbecd0f581e4715540213a65eb7da" @@ -7935,18 +7313,6 @@ registry-url@^5.0.0: dependencies: rc "^1.2.8" -regjsgen@^0.5.1: - version "0.5.2" - resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.5.2.tgz#92ff295fb1deecbf6ecdab2543d207e91aa33733" - integrity sha512-OFFT3MfrH90xIW8OOSyUrk6QHD5E9JOTeGodiJeBS3J6IwlgzJMNE/1bZklWz5oTg+9dCMyEetclvCVXOPoN3A== - -regjsparser@^0.6.4: - version "0.6.9" - resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.6.9.tgz#b489eef7c9a2ce43727627011429cf833a7183e6" - integrity sha512-ZqbNRz1SNjLAiYuwY0zoXW8Ne675IX5q+YHioAGbCw4X96Mjl2+dcX9B2ciaeyYjViDAfvIjFpQjJgLttTEERQ== - dependencies: - jsesc "~0.5.0" - remove-trailing-separator@^1.0.1: version "1.1.0" resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" @@ -8065,7 +7431,7 @@ resolve-url@^0.2.1: resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" integrity sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo= -resolve@^1.1.4, resolve@^1.1.5, resolve@^1.1.6, resolve@^1.10.0, resolve@^1.11.0, resolve@^1.11.1, resolve@^1.14.2, resolve@^1.17.0, resolve@^1.20.0, resolve@^1.4.0: +resolve@^1.1.4, resolve@^1.1.5, resolve@^1.1.6, resolve@^1.10.0, resolve@^1.11.0, resolve@^1.11.1, resolve@^1.17.0, resolve@^1.20.0, resolve@^1.4.0: version "1.20.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.20.0.tgz#629a013fb3f70755d6f0b7935cc1c2c5378b1975" integrity sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A== @@ -8125,6 +7491,13 @@ robots-parser@^2.0.1: resolved "https://registry.npmjs.org/robots-parser/-/robots-parser-2.1.0.tgz#d16b78ce34e861ab6afbbf0aac65974dbe01566e" integrity sha512-k07MeDS1Tl1zjoYs5bHfUbgQ0MfaeTOepDcjZFxdYXd84p6IeLDQyUwlMk2AZ9c2yExA30I3ayWhmqz9tg0DzQ== +rollup-plugin-brfs@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/rollup-plugin-brfs/-/rollup-plugin-brfs-1.0.1.tgz#9b618bb163e41662b019afcd94f9d63b71d9d6aa" + integrity sha512-Kp3UbCNnJKqy1U4+q7HUNzVznHEYiHq9fxcOUhmAZLI9ks2iT8ITJPSdddbRjCmlbmbDvUSw28IvyE6bWrbr7g== + dependencies: + brfs "^2.0.2" + rollup-plugin-commonjs@^10.1.0: version "10.1.0" resolved "https://registry.yarnpkg.com/rollup-plugin-commonjs/-/rollup-plugin-commonjs-10.1.0.tgz#417af3b54503878e084d127adf4d1caf8beb86fb" @@ -8136,11 +7509,6 @@ rollup-plugin-commonjs@^10.1.0: resolve "^1.11.0" rollup-pluginutils "^2.8.1" -rollup-plugin-ignore@^1.0.9: - version "1.0.9" - resolved "https://registry.yarnpkg.com/rollup-plugin-ignore/-/rollup-plugin-ignore-1.0.9.tgz#62a692d387d543395ad2fbcc443c9b3549582844" - integrity sha512-+Q2jmD4gbO3ByFuljkDEfpEcYvll7J5+ZadUuk/Pu35x2KGrbHxKtt3+s+dPIgXX1mG7zCxG4s/NdRqztR5Ruw== - rollup-plugin-inject@^3.0.0: version "3.0.2" resolved "https://registry.yarnpkg.com/rollup-plugin-inject/-/rollup-plugin-inject-3.0.2.tgz#e4233855bfba6c0c12a312fd6649dff9a13ee9f4" @@ -8150,17 +7518,15 @@ rollup-plugin-inject@^3.0.0: magic-string "^0.25.3" rollup-pluginutils "^2.8.1" -rollup-plugin-node-globals@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/rollup-plugin-node-globals/-/rollup-plugin-node-globals-1.4.0.tgz#5e1f24a9bb97c0ef51249f625e16c7e61b7c020b" - integrity sha512-xRkB+W/m1KLIzPUmG0ofvR+CPNcvuCuNdjVBVS7ALKSxr3EDhnzNceGkGi1m8MToSli13AzKFYH4ie9w3I5L3g== +rollup-plugin-node-builtins@^2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/rollup-plugin-node-builtins/-/rollup-plugin-node-builtins-2.1.2.tgz#24a1fed4a43257b6b64371d8abc6ce1ab14597e9" + integrity sha1-JKH+1KQyV7a2Q3HYq8bOGrFFl+k= dependencies: - acorn "^5.7.3" - buffer-es6 "^4.9.3" - estree-walker "^0.5.2" - magic-string "^0.22.5" - process-es6 "^0.11.6" - rollup-pluginutils "^2.3.1" + browserify-fs "^1.0.0" + buffer-es6 "^4.9.2" + crypto-browserify "^3.11.0" + process-es6 "^0.11.2" rollup-plugin-node-polyfills@^0.2.1: version "0.2.1" @@ -8180,22 +7546,40 @@ rollup-plugin-node-resolve@^5.2.0: resolve "^1.11.1" rollup-pluginutils "^2.8.1" +rollup-plugin-replace@^2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/rollup-plugin-replace/-/rollup-plugin-replace-2.2.0.tgz#f41ae5372e11e7a217cde349c8b5d5fd115e70e3" + integrity sha512-/5bxtUPkDHyBJAKketb4NfaeZjL5yLZdeUihSfbF2PQMz+rSTEb8ARKoOl3UBT4m7/X+QOXJo3sLTcq+yMMYTA== + dependencies: + magic-string "^0.25.2" + rollup-pluginutils "^2.6.0" + rollup-plugin-shim@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/rollup-plugin-shim/-/rollup-plugin-shim-1.0.0.tgz#b00f5cb44cdae81358c5342fe82fa71a1602b56b" integrity sha512-rZqFD43y4U9nSqVq3iyWBiDwmBQJY8Txi04yI9jTKD3xcl7CbFjh1qRpQshUB3sONLubDzm7vJiwB+1MEGv67w== -rollup-pluginutils@^2.3.1, rollup-pluginutils@^2.8.1: +rollup-plugin-terser@^7.0.2: + version "7.0.2" + resolved "https://registry.yarnpkg.com/rollup-plugin-terser/-/rollup-plugin-terser-7.0.2.tgz#e8fbba4869981b2dc35ae7e8a502d5c6c04d324d" + integrity sha512-w3iIaU4OxcF52UUXiZNsNeuXIMDvFrr+ZXK6bFZ0Q60qyVfq4uLptoS4bbq3paG3x216eQllFZX7zt6TIImguQ== + dependencies: + "@babel/code-frame" "^7.10.4" + jest-worker "^26.2.1" + serialize-javascript "^4.0.0" + terser "^5.0.0" + +rollup-pluginutils@^2.6.0, rollup-pluginutils@^2.8.1: version "2.8.2" resolved "https://registry.yarnpkg.com/rollup-pluginutils/-/rollup-pluginutils-2.8.2.tgz#72f2af0748b592364dbd3389e600e5a9444a351e" integrity sha512-EEp9NhnUkwY8aif6bxgovPHMoMoNr2FulJziTndpt5H9RdwC47GSGuII9XxpSdzVGM0GWrNPHV6ie1LTNJPaLQ== dependencies: estree-walker "^0.6.1" -rollup@^2.52.6: - version "2.52.6" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.52.6.tgz#7c7546d170dead0e7db0b6c709f7f34398498a8e" - integrity sha512-H+Xudmwf8KO+xji8njQNoIQRp8l+iQge/NdUR20JngTxVYdEEnlpkMvQ71YGLl3+xZcPecmdj4q2lrClKaPdRA== +rollup@^2.52.7: + version "2.52.7" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.52.7.tgz#e15a8bf734f6e4c204b7cdf33521151310250cb2" + integrity sha512-55cSH4CCU6MaPr9TAOyrIC+7qFCHscL7tkNsm1MBfIJRRqRbCEY0mmeFn4Wg8FKsHtEH8r389Fz38r/o+kgXLg== optionalDependencies: fsevents "~2.3.2" @@ -8276,12 +7660,7 @@ semver-diff@^3.1.1: resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== -semver@7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.0.0.tgz#5f3ca35761e47e05b206c6daff2cf814f0316b8e" - integrity sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A== - -semver@^6.0.0, semver@^6.1.1, semver@^6.1.2, semver@^6.2.0, semver@^6.3.0: +semver@^6.0.0, semver@^6.2.0, semver@^6.3.0: version "6.3.0" resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== @@ -8293,6 +7672,18 @@ semver@^7.2.1, semver@^7.3.2: dependencies: lru-cache "^6.0.0" +semver@~2.3.1: + version "2.3.2" + resolved "https://registry.yarnpkg.com/semver/-/semver-2.3.2.tgz#b9848f25d6cf36333073ec9ef8856d42f1233e52" + integrity sha1-uYSPJdbPNjMwc+ye+IVtQvEjPlI= + +serialize-javascript@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/serialize-javascript/-/serialize-javascript-4.0.0.tgz#b525e1238489a5ecfc42afacc3fe99e666f4b1aa" + integrity sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw== + dependencies: + randombytes "^2.1.0" + set-blocking@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" @@ -8662,6 +8053,11 @@ string-length@^4.0.1: char-regex "^1.0.2" strip-ansi "^6.0.0" +string-range@~1.2, string-range@~1.2.1: + version "1.2.2" + resolved "https://registry.yarnpkg.com/string-range/-/string-range-1.2.2.tgz#a893ed347e72299bc83befbbf2a692a8d239d5dd" + integrity sha1-qJPtNH5yKZvIO++78qaSqNI51d0= + string-width@^3.0.0, string-width@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/string-width/-/string-width-3.1.0.tgz#22767be21b62af1081574306f69ac51b62203961" @@ -8703,6 +8099,11 @@ string_decoder@^1.1.1: dependencies: safe-buffer "~5.2.0" +string_decoder@~0.10.x: + version "0.10.31" + resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" + integrity sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ= + string_decoder@~1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" @@ -8901,6 +8302,15 @@ terminal-link@^2.0.0: ansi-escapes "^4.2.1" supports-hyperlinks "^2.0.0" +terser@^5.0.0: + version "5.7.1" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.7.1.tgz#2dc7a61009b66bb638305cb2a824763b116bf784" + integrity sha512-b3e+d5JbHAe/JSjwsC3Zn55wsBIM7AsHLjKxT31kGCldgbpFePaFo+PiddtO6uwRZWRw7sPXmAN8dTW61xmnSg== + dependencies: + commander "^2.20.0" + source-map "~0.7.2" + source-map-support "~0.5.19" + terser@^5.3.8: version "5.3.8" resolved "https://registry.yarnpkg.com/terser/-/terser-5.3.8.tgz#991ae8ba21a3d990579b54aa9af11586197a75dd" @@ -9173,6 +8583,11 @@ typedarray-to-buffer@^3.1.5: dependencies: is-typedarray "^1.0.0" +typedarray-to-buffer@~1.0.0: + version "1.0.4" + resolved "https://registry.yarnpkg.com/typedarray-to-buffer/-/typedarray-to-buffer-1.0.4.tgz#9bb8ba0e841fb3f4cf1fe7c245e9f3fa8a5fe99c" + integrity sha1-m7i6DoQfs/TPH+fCRenz+opf6Zw= + typedarray@^0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" @@ -9230,29 +8645,6 @@ underscore@^1.9.1: resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.13.1.tgz#0c1c6bd2df54b6b69f2314066d65b6cde6fcf9d1" integrity sha512-hzSoAVtJF+3ZtiFX0VgfFPHEDRm7Y/QPjGyNo4TVdnDTdft3tr8hEkD25a1jC+TjTuE7tkHGKkhwCgs9dgBB2g== -unicode-canonical-property-names-ecmascript@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-1.0.4.tgz#2619800c4c825800efdd8343af7dd9933cbe2818" - integrity sha512-jDrNnXWHd4oHiTZnx/ZG7gtUTVp+gCcTTKr8L0HjlwphROEW3+Him+IpvC+xcJEFegapiMZyZe02CyuOnRmbnQ== - -unicode-match-property-ecmascript@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/unicode-match-property-ecmascript/-/unicode-match-property-ecmascript-1.0.4.tgz#8ed2a32569961bce9227d09cd3ffbb8fed5f020c" - integrity sha512-L4Qoh15vTfntsn4P1zqnHulG0LdXgjSO035fEpdtp6YxXhMT51Q6vgM5lYdG/5X3MjS+k/Y9Xw4SFCY9IkR0rg== - dependencies: - unicode-canonical-property-names-ecmascript "^1.0.4" - unicode-property-aliases-ecmascript "^1.0.4" - -unicode-match-property-value-ecmascript@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.2.0.tgz#0d91f600eeeb3096aa962b1d6fc88876e64ea531" - integrity sha512-wjuQHGQVofmSJv1uVISKLE5zO2rNGzM/KCYZch/QQvez7C1hUhBIuZ701fYXExuufJFMPhv2SyL8CyoIfMLbIQ== - -unicode-property-aliases-ecmascript@^1.0.4: - version "1.1.0" - resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.1.0.tgz#dd57a99f6207bedff4628abefb94c50db941c8f4" - integrity sha512-PqSoPh/pWetQ2phoj5RLiaqIk4kCNwoV3CI+LfGmWLKI3rE3kl1h59XpX2BjgDrmbxD9ARtQobPGU1SguCYuQg== - union-value@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/union-value/-/union-value-1.0.1.tgz#0b6fe7b835aecda61c6ea4d4f02c14221e109847" @@ -9411,11 +8803,6 @@ verror@1.3.6: dependencies: extsprintf "1.0.2" -vlq@^0.2.2: - version "0.2.3" - resolved "https://registry.yarnpkg.com/vlq/-/vlq-0.2.3.tgz#8f3e4328cf63b1540c0d67e1b2778386f8975b26" - integrity sha512-DRibZL6DsNhIgYQ+wNdWDL2SL3bKPlVrRiBqV5yuMm++op8W4kGFtaQfCs4KEJn0wBZcHVHJ3eoywX8983k1ow== - vm-browserify@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/vm-browserify/-/vm-browserify-1.1.0.tgz#bd76d6a23323e2ca8ffa12028dc04559c75f9019" @@ -9640,11 +9027,36 @@ xmlchars@^2.2.0: resolved "https://registry.yarnpkg.com/xmlchars/-/xmlchars-2.2.0.tgz#060fe1bcb7f9c76fe2a17db86a9bc3ab894210cb" integrity sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw== +xtend@^2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/xtend/-/xtend-2.2.0.tgz#eef6b1f198c1c8deafad8b1765a04dad4a01c5a9" + integrity sha1-7vax8ZjByN6vrYsXZaBNrUoBxak= + xtend@^4.0.0, xtend@^4.0.1, xtend@^4.0.2, xtend@~4.0.1: version "4.0.2" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== +xtend@~2.0.4: + version "2.0.6" + resolved "https://registry.yarnpkg.com/xtend/-/xtend-2.0.6.tgz#5ea657a6dba447069c2e59c58a1138cb0c5e6cee" + integrity sha1-XqZXptukRwacLlnFihE4ywxebO4= + dependencies: + is-object "~0.1.2" + object-keys "~0.2.0" + +xtend@~2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/xtend/-/xtend-2.1.2.tgz#6efecc2a4dad8e6962c4901b337ce7ba87b5d28b" + integrity sha1-bv7MKk2tjmlixJAbM3znuoe10os= + dependencies: + object-keys "~0.4.0" + +xtend@~3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/xtend/-/xtend-3.0.0.tgz#5cce7407baf642cba7becda568111c493f59665a" + integrity sha1-XM50B7r2Qsunvs2laBEcST9ZZlo= + y18n@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/y18n/-/y18n-4.0.1.tgz#8db2b83c31c5d75099bb890b23f3094891e247d4" From 3050c683f70e89bfbf2157958b98451c48014654 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Wed, 7 Jul 2021 13:07:32 -0700 Subject: [PATCH 03/36] pubads working --- build/build-bundle.js | 24 ++++++++++++------------ clients/devtools-entry.js | 2 +- lighthouse-core/config/config-helpers.js | 2 +- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index f69f6f7167ca..40f7bb60d8ea 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -187,7 +187,6 @@ async function minifyScript(filePath) { async function build(entryPath, distPath) { const rollup = require('rollup'); const {terser} = require('rollup-plugin-terser'); - // Only needed b/c getFilenamePrefix loads a commonjs module. const commonjs = // @ts-expect-error types are wrong. /** @type {import('rollup-plugin-commonjs').default} */ (require('rollup-plugin-commonjs')); @@ -201,11 +200,10 @@ async function build(entryPath, distPath) { // Include lighthouse-plugin-publisher-ads. if (isDevtools(entryPath) || isLightrider(entryPath)) { - // TODO: doesn't work yet (circular deps?) - // dynamicModulePaths.push('lighthouse-plugin-publisher-ads'); - // pubAdsAudits.forEach(pubAdAudit => { - // dynamicModulePaths.push(pubAdAudit); - // }); + dynamicModulePaths.push('lighthouse-plugin-publisher-ads'); + pubAdsAudits.forEach(pubAdAudit => { + dynamicModulePaths.push(pubAdAudit); + }); } const bundledMapEntriesCode = dynamicModulePaths.map(modulePath => { @@ -215,6 +213,7 @@ async function build(entryPath, distPath) { const shimsObj = {}; const modulesToIgnore = [ + 'http', 'intl-pluralrules', 'intl', 'pako/lib/zlib/inflate.js', @@ -251,8 +250,7 @@ async function build(entryPath, distPath) { require('rollup-plugin-replace')({ delimiters: ['', ''], values: { - 'const bundledModules = new Map();': - `const bundledModules = new Map([\n${bundledMapEntriesCode},\n]);`, + '/* BUILD_REPLACE_BUNDLED_MODULES */': `[\n${bundledMapEntriesCode},\n]`, '__dirname': (id) => `'${path.relative(LH_ROOT, path.dirname(id))}'`, '__filename': (id) => `'${path.relative(LH_ROOT, id)}'`, }, @@ -261,10 +259,12 @@ async function build(entryPath, distPath) { ...shimsObj, 'debug': `export * from '${require.resolve('debug/src/browser.js')}'`, + 'url': `import URL from '${require.resolve('../lighthouse-core/lib/url-shim.js')}'; export {URL};`, // 'lighthouse-logger': 'export default {}', // This allows for plugins to import lighthouse. TODO: lol no it doesnt - // [require.resolve('lighthouse')]: 'export {__moduleExports: {Audit: 1}};', + // ['lighthouse']: `export default await import('${require.resolve('../lighthouse-core/index.js')}');`, + 'lighthouse': `import Audit from '${require.resolve('../lighthouse-core/audits/audit.js')}'; export {Audit};`, // [require.resolve('debug/node')]: 'export default {}', // 'intl-pluralrules': 'export default {}', // 'intl': 'export default {}', @@ -286,12 +286,12 @@ async function build(entryPath, distPath) { }), require('rollup-plugin-node-resolve')({preferBuiltins: true}), - require('rollup-plugin-node-builtins')(), + // require('rollup-plugin-node-builtins')(), require('rollup-plugin-node-polyfills')(), // Rollup sees the usages of these functions in page functions (ex: see AnchorElements) // and treats them as globals. Because the names are "taken" by the global, Rollup renames - // the actual functions. The page functions expect a certain name, and so here we undo what - // Rollup did. + // the actual functions (getNodeDetails$1). The page functions expect a certain name, so + // here we undo what Rollup did. require('./rollup-postprocess.js')([ [/getElementsInDocument\$1/, 'getElementsInDocument'], [/getNodeDetails\$1/, 'getNodeDetails'], diff --git a/clients/devtools-entry.js b/clients/devtools-entry.js index 2dc4ef8093e1..bb28f891e134 100644 --- a/clients/devtools-entry.js +++ b/clients/devtools-entry.js @@ -41,7 +41,7 @@ function createConfig(categoryIDs, device) { return { extends: 'lighthouse:default', - // plugins: ['lighthouse-plugin-publisher-ads'], + plugins: ['lighthouse-plugin-publisher-ads'], settings, }; } diff --git a/lighthouse-core/config/config-helpers.js b/lighthouse-core/config/config-helpers.js index 238e7f0c82ad..0b9de7730a7c 100644 --- a/lighthouse-core/config/config-helpers.js +++ b/lighthouse-core/config/config-helpers.js @@ -219,7 +219,7 @@ function expandAuditShorthand(audit) { } /** @type {Map} */ -const bundledModules = new Map(); +const bundledModules = new Map(/* BUILD_REPLACE_BUNDLED_MODULES */); /** * Wraps `require` with an entrypoint for bundled dynamic modules. From aaaf2de14b868be68ffedcc24e8b45cf70b28de9 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Wed, 7 Jul 2021 13:17:14 -0700 Subject: [PATCH 04/36] wip sourcemap --- build/build-bundle.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index 40f7bb60d8ea..65e69a0e9947 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -307,10 +307,6 @@ async function build(entryPath, distPath) { keep_classnames: true, // Runtime.evaluate errors if function names are elided. keep_fnames: true, - // sourceMap: DEBUG && { - // content: JSON.parse(fs.readFileSync(`${filePath}.map`, 'utf-8')), - // url: path.basename(`${filePath}.map`), - // }, }), ], }); @@ -318,6 +314,7 @@ async function build(entryPath, distPath) { await bundle.write({ file: distPath, format: 'iife', + sourcemap: DEBUG, }); // await browserifyFile(entryPath, distPath); From 229ae003eecfc496e4878db44a7269b863e851cd Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Wed, 7 Jul 2021 13:47:27 -0700 Subject: [PATCH 05/36] update --- build/build-bundle.js | 32 ++--- package.json | 2 +- yarn.lock | 296 ++---------------------------------------- 3 files changed, 20 insertions(+), 310 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index 65e69a0e9947..5dbecd5c1f30 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -213,13 +213,13 @@ async function build(entryPath, distPath) { const shimsObj = {}; const modulesToIgnore = [ - 'http', 'intl-pluralrules', 'intl', 'pako/lib/zlib/inflate.js', 'raven', 'source-map', 'ws', + require.resolve('../lighthouse-core/gather/connections/cri.js'), ]; // Don't include the stringified report in DevTools - see devtools-report-assets.js @@ -240,8 +240,6 @@ async function build(entryPath, distPath) { shimsObj[modulePath] = 'export default {}'; } - // rollup inject? - const bundle = await rollup.rollup({ input: entryPath, context: 'globalThis', @@ -255,38 +253,29 @@ async function build(entryPath, distPath) { '__filename': (id) => `'${path.relative(LH_ROOT, id)}'`, }, }), + require('@rollup/plugin-alias')({ + entries: { + debug: require.resolve('debug/src/browser.js'), + url: require.resolve('../lighthouse-core/lib/url-shim.js'), + }, + }), require('rollup-plugin-shim')({ ...shimsObj, - - 'debug': `export * from '${require.resolve('debug/src/browser.js')}'`, - 'url': `import URL from '${require.resolve('../lighthouse-core/lib/url-shim.js')}'; export {URL};`, - // 'lighthouse-logger': 'export default {}', - - // This allows for plugins to import lighthouse. TODO: lol no it doesnt - // ['lighthouse']: `export default await import('${require.resolve('../lighthouse-core/index.js')}');`, + // Allows for plugins to import lighthouse. 'lighthouse': `import Audit from '${require.resolve('../lighthouse-core/audits/audit.js')}'; export {Audit};`, - // [require.resolve('debug/node')]: 'export default {}', - // 'intl-pluralrules': 'export default {}', - // 'intl': 'export default {}', - // 'pako/lib/zlib/inflate.js': 'export default {}', - // 'raven': 'export default {}', - // 'source-map': 'export default {}', - // 'ws': 'export default {}', }), // Currently must run before commonjs (brfs does not support import). + // This currenty messes up source maps. rollupBrfs({ readFileSyncTransform: minifyFileTransform, global: true, parserOpts: {ecmaVersion: 12, sourceType: 'module'}, }), - commonjs({ // https://github.com/rollup/plugins/issues/922 ignoreGlobal: true, }), - require('rollup-plugin-node-resolve')({preferBuiltins: true}), - // require('rollup-plugin-node-builtins')(), require('rollup-plugin-node-polyfills')(), // Rollup sees the usages of these functions in page functions (ex: see AnchorElements) // and treats them as globals. Because the names are "taken" by the global, Rollup renames @@ -316,9 +305,6 @@ async function build(entryPath, distPath) { format: 'iife', sourcemap: DEBUG, }); - - // await browserifyFile(entryPath, distPath); - // await minifyScript(distPath); } /** diff --git a/package.json b/package.json index a3b2b173b454..e2111473f985 100644 --- a/package.json +++ b/package.json @@ -92,6 +92,7 @@ "@firebase/app-types": "0.3.1", "@firebase/auth-types": "0.3.2", "@firebase/util": "0.2.1", + "@rollup/plugin-alias": "^3.1.2", "@rollup/plugin-dynamic-import-vars": "^1.1.1", "@rollup/plugin-json": "^4.1.0", "@types/archiver": "^2.1.2", @@ -159,7 +160,6 @@ "rollup": "^2.52.7", "rollup-plugin-brfs": "^1.0.1", "rollup-plugin-commonjs": "^10.1.0", - "rollup-plugin-node-builtins": "^2.1.2", "rollup-plugin-node-polyfills": "^0.2.1", "rollup-plugin-node-resolve": "^5.2.0", "rollup-plugin-replace": "^2.2.0", diff --git a/yarn.lock b/yarn.lock index 5d61950556dc..78342e3419b6 100644 --- a/yarn.lock +++ b/yarn.lock @@ -763,6 +763,13 @@ "@nodelib/fs.scandir" "2.1.3" fastq "^1.6.0" +"@rollup/plugin-alias@^3.1.2": + version "3.1.2" + resolved "https://registry.yarnpkg.com/@rollup/plugin-alias/-/plugin-alias-3.1.2.tgz#c585b05be4a7782d269c69d13def56f44e417772" + integrity sha512-wzDnQ6v7CcoRzS0qVwFPrFdYA4Qlr+ookA217Y2Z3DPZE1R8jrFNM3jvGgOf6o6DMjbnQIn5lCIJgHPe1Bt3uw== + dependencies: + slash "^3.0.0" + "@rollup/plugin-dynamic-import-vars@^1.1.1": version "1.1.1" resolved "https://registry.yarnpkg.com/@rollup/plugin-dynamic-import-vars/-/plugin-dynamic-import-vars-1.1.1.tgz#d72142fd9e450bcf5e17624adf4f4d4c25d7daec" @@ -1262,13 +1269,6 @@ abort-controller@^3.0.0: dependencies: event-target-shim "^5.0.0" -abstract-leveldown@~0.12.0, abstract-leveldown@~0.12.1: - version "0.12.4" - resolved "https://registry.yarnpkg.com/abstract-leveldown/-/abstract-leveldown-0.12.4.tgz#29e18e632e60e4e221d5810247852a63d7b2e410" - integrity sha1-KeGOYy5g5OIh1YECR4UqY9ey5BA= - dependencies: - xtend "~3.0.0" - acorn-globals@^4.3.0: version "4.3.2" resolved "https://registry.yarnpkg.com/acorn-globals/-/acorn-globals-4.3.2.tgz#4e2c2313a597fd589720395f6354b41cd5ec8006" @@ -1723,13 +1723,6 @@ bl@^4.0.3: inherits "^2.0.4" readable-stream "^3.4.0" -bl@~0.8.1: - version "0.8.2" - resolved "https://registry.yarnpkg.com/bl/-/bl-0.8.2.tgz#c9b6bca08d1bc2ea00fc8afb4f1a5fd1e1c66e4e" - integrity sha1-yba8oI0bwuoA/Ir7Txpf0eHGbk4= - dependencies: - readable-stream "~1.0.26" - bn.js@^4.0.0, bn.js@^4.1.0, bn.js@^4.1.1, bn.js@^4.11.9: version "4.12.0" resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.12.0.tgz#775b3f278efbb9718eec7361f483fb36fbbfea88" @@ -1871,15 +1864,6 @@ browserify-des@^1.0.0: inherits "^2.0.1" safe-buffer "^5.1.2" -browserify-fs@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/browserify-fs/-/browserify-fs-1.0.0.tgz#f075aa8a729d4d1716d066620e386fcc1311a96f" - integrity sha1-8HWqinKdTRcW0GZiDjhvzBMRqW8= - dependencies: - level-filesystem "^1.0.1" - level-js "^2.1.3" - levelup "^0.18.2" - browserify-package-json@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/browserify-package-json/-/browserify-package-json-1.0.1.tgz#98dde8aa5c561fd6d3fe49bbaa102b74b396fdea" @@ -2019,11 +2003,6 @@ buffer-equal@0.0.1: resolved "https://registry.yarnpkg.com/buffer-equal/-/buffer-equal-0.0.1.tgz#91bc74b11ea405bc916bc6aa908faafa5b4aac4b" integrity sha1-kbx0sR6kBbyRa8aqkI+q+ltKrEs= -buffer-es6@^4.9.2: - version "4.9.3" - resolved "https://registry.yarnpkg.com/buffer-es6/-/buffer-es6-4.9.3.tgz#f26347b82df76fd37e18bcb5288c4970cfd5c404" - integrity sha1-8mNHuC33b9N+GLy1KIxJcM/VxAQ= - buffer-fill@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/buffer-fill/-/buffer-fill-1.0.0.tgz#f8f78b76789888ef39f205cd637f68e702122b2c" @@ -2384,11 +2363,6 @@ clone@^1.0.2: resolved "https://registry.yarnpkg.com/clone/-/clone-1.0.4.tgz#da309cc263df15994c688ca902179ca3c7cd7c7e" integrity sha1-2jCcwmPfFZlMaIypAheco8fNfH4= -clone@~0.1.9: - version "0.1.19" - resolved "https://registry.yarnpkg.com/clone/-/clone-0.1.19.tgz#613fb68639b26a494ac53253e15b1a6bd88ada85" - integrity sha1-YT+2hjmyaklKxTJT4Vsaa9iK2oU= - co@^4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" @@ -2498,7 +2472,7 @@ concat-map@0.0.1: resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= -concat-stream@^1.4.4, concat-stream@^1.6.0, concat-stream@^1.6.1, concat-stream@~1.6.0: +concat-stream@^1.6.0, concat-stream@^1.6.1, concat-stream@~1.6.0: version "1.6.2" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" integrity sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw== @@ -2800,7 +2774,7 @@ cross-spawn@^7.0.0, cross-spawn@^7.0.1, cross-spawn@^7.0.2, cross-spawn@^7.0.3: shebang-command "^2.0.0" which "^2.0.1" -crypto-browserify@^3.0.0, crypto-browserify@^3.11.0: +crypto-browserify@^3.0.0: version "3.12.0" resolved "https://registry.yarnpkg.com/crypto-browserify/-/crypto-browserify-3.12.0.tgz#396cf9f3137f03e4b8e532c58f698254e00f80ec" integrity sha512-fz4spIh+znjO2VjL+IdhEpRJ3YN6sMzITSBijk6FK2UvTqruSQW+/cCZTSNsMiZNvUeq0CqurF+dAbyiGOY6Wg== @@ -3011,13 +2985,6 @@ defer-to-connect@^1.0.1: resolved "https://registry.yarnpkg.com/defer-to-connect/-/defer-to-connect-1.1.3.tgz#331ae050c08dcf789f8c83a7b81f0ed94f4ac591" integrity sha512-0ISdNousHvZT2EiFlZeZAHBUvSxmKswVCEf8hW7KWgG4a8MVEu/3Vb6uWYozkjylyCxe0JBIiRB1jV45S70WVQ== -deferred-leveldown@~0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/deferred-leveldown/-/deferred-leveldown-0.2.0.tgz#2cef1f111e1c57870d8bbb8af2650e587cd2f5b4" - integrity sha1-LO8fER4cV4cNi7uK8mUOWHzS9bQ= - dependencies: - abstract-leveldown "~0.12.1" - define-properties@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" @@ -3254,13 +3221,6 @@ enquirer@^2.3.5, enquirer@^2.3.6: dependencies: ansi-colors "^4.1.1" -errno@^0.1.1, errno@~0.1.1: - version "0.1.8" - resolved "https://registry.yarnpkg.com/errno/-/errno-0.1.8.tgz#8bb3e9c7d463be4976ff888f76b4809ebc2e811f" - integrity sha512-dJ6oBr5SQ1VSd9qkk7ByRgb/1SH4JZjCHSW/mr63/QcXO9zLVxvJ6Oy13nio03rxpSnVDDjFor75SjVeZWPW/A== - dependencies: - prr "~1.0.1" - error-ex@^1.2.0, error-ex@^1.3.1: version "1.3.2" resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" @@ -3865,7 +3825,7 @@ for-in@^1.0.2: resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" integrity sha1-gQaNKVqBQuwKxybG4iAMMPttXoA= -foreach@^2.0.5, foreach@~2.0.1: +foreach@^2.0.5: version "2.0.5" resolved "https://registry.yarnpkg.com/foreach/-/foreach-2.0.5.tgz#0bee005018aeb260d0a3af3ae658dd0136ec1b99" integrity sha1-C+4AUBiusmDQo6865ljdATbsG5k= @@ -3950,13 +3910,6 @@ furi@^2.0.0: "@types/is-windows" "^1.0.0" is-windows "^1.0.2" -fwd-stream@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/fwd-stream/-/fwd-stream-1.0.4.tgz#ed281cabed46feecf921ee32dc4c50b372ac7cfa" - integrity sha1-7Sgcq+1G/uz5Ie4y3ExQs3KsfPo= - dependencies: - readable-stream "~1.0.26-4" - gensync@^1.0.0-beta.2: version "1.0.0-beta.2" resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" @@ -4413,11 +4366,6 @@ idb-keyval@2.2.0: resolved "https://registry.yarnpkg.com/idb-keyval/-/idb-keyval-2.2.0.tgz#b28020d53e3cf1621e3ec605e57e5305f37b195e" integrity sha1-soAg1T488WIePsYF5X5TBfN7GV4= -idb-wrapper@^1.5.0: - version "1.7.2" - resolved "https://registry.yarnpkg.com/idb-wrapper/-/idb-wrapper-1.7.2.tgz#8251afd5e77fe95568b1c16152eb44b396767ea2" - integrity sha512-zfNREywMuf0NzDo9mVsL0yegjsirJxHpKHvWcyRozIqQy89g0a3U+oBPOCN4cc0oCiOuYgZHimzaW/R46G1Mpg== - ieee754@^1.1.13: version "1.2.1" resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" @@ -4494,11 +4442,6 @@ indent-string@^4.0.0: resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-4.0.0.tgz#624f8f4497d619b2d9768531d58f4122854d7251" integrity sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg== -indexof@~0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/indexof/-/indexof-0.0.1.tgz#82dc336d232b9062179d05ab3293a66059fd435d" - integrity sha1-gtwzbSMrkGIXnQWrMpOmYFn9Q10= - inflight@^1.0.4: version "1.0.6" resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" @@ -4815,11 +4758,6 @@ is-obj@^2.0.0: resolved "https://registry.yarnpkg.com/is-obj/-/is-obj-2.0.0.tgz#473fb05d973705e3fd9620545018ca8e22ef4982" integrity sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w== -is-object@~0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/is-object/-/is-object-0.1.2.tgz#00efbc08816c33cfc4ac8251d132e10dc65098d7" - integrity sha1-AO+8CIFsM8/ErIJR0TLhDcZQmNc= - is-odd@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-odd/-/is-odd-2.0.0.tgz#7646624671fd7ea558ccd9a2795182f2958f1b24" @@ -4941,16 +4879,6 @@ is-yarn-global@^0.3.0: resolved "https://registry.yarnpkg.com/is-yarn-global/-/is-yarn-global-0.3.0.tgz#d502d3382590ea3004893746754c89139973e232" integrity sha512-VjSeb/lHmkoyd8ryPVIKvOCn4D1koMqY+vqyjjUfc3xyKtP4dYOxM44sZrnqQSzSds3xyOrUTLTC9LVCVgLngw== -is@~0.2.6: - version "0.2.7" - resolved "https://registry.yarnpkg.com/is/-/is-0.2.7.tgz#3b34a2c48f359972f35042849193ae7264b63562" - integrity sha1-OzSixI81mXLzUEKEkZOucmS2NWI= - -isarray@0.0.1: - version "0.0.1" - resolved "https://registry.yarnpkg.com/isarray/-/isarray-0.0.1.tgz#8a18acfca9a8f4177e09abfc6038939b05d1eedf" - integrity sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8= - isarray@1.0.0, isarray@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" @@ -4961,11 +4889,6 @@ isarray@^2.0.4: resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.4.tgz#38e7bcbb0f3ba1b7933c86ba1894ddfc3781bbb7" integrity sha512-GMxXOiUirWg1xTKRipM0Ek07rX+ubx4nNVElTJdNLYmNO/2YrDkgJGw9CljXn+r4EWiDQg/8lsRdHyg2PJuUaA== -isbuffer@~0.0.0: - version "0.0.0" - resolved "https://registry.yarnpkg.com/isbuffer/-/isbuffer-0.0.0.tgz#38c146d9df528b8bf9b0701c3d43cf12df3fc39b" - integrity sha1-OMFG2d9Si4v5sHAcPUPPEt8/w5s= - isexe@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" @@ -5711,91 +5634,6 @@ lazystream@^1.0.0: dependencies: readable-stream "^2.0.5" -level-blobs@^0.1.7: - version "0.1.7" - resolved "https://registry.yarnpkg.com/level-blobs/-/level-blobs-0.1.7.tgz#9ab9b97bb99f1edbf9f78a3433e21ed56386bdaf" - integrity sha1-mrm5e7mfHtv594o0M+Ie1WOGva8= - dependencies: - level-peek "1.0.6" - once "^1.3.0" - readable-stream "^1.0.26-4" - -level-filesystem@^1.0.1: - version "1.2.0" - resolved "https://registry.yarnpkg.com/level-filesystem/-/level-filesystem-1.2.0.tgz#a00aca9919c4a4dfafdca6a8108d225aadff63b3" - integrity sha1-oArKmRnEpN+v3KaoEI0iWq3/Y7M= - dependencies: - concat-stream "^1.4.4" - errno "^0.1.1" - fwd-stream "^1.0.4" - level-blobs "^0.1.7" - level-peek "^1.0.6" - level-sublevel "^5.2.0" - octal "^1.0.0" - once "^1.3.0" - xtend "^2.2.0" - -level-fix-range@2.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/level-fix-range/-/level-fix-range-2.0.0.tgz#c417d62159442151a19d9a2367868f1724c2d548" - integrity sha1-xBfWIVlEIVGhnZojZ4aPFyTC1Ug= - dependencies: - clone "~0.1.9" - -level-fix-range@~1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/level-fix-range/-/level-fix-range-1.0.2.tgz#bf15b915ae36d8470c821e883ddf79cd16420828" - integrity sha1-vxW5Fa422EcMgh6IPd95zRZCCCg= - -"level-hooks@>=4.4.0 <5": - version "4.5.0" - resolved "https://registry.yarnpkg.com/level-hooks/-/level-hooks-4.5.0.tgz#1b9ae61922930f3305d1a61fc4d83c8102c0dd93" - integrity sha1-G5rmGSKTDzMF0aYfxNg8gQLA3ZM= - dependencies: - string-range "~1.2" - -level-js@^2.1.3: - version "2.2.4" - resolved "https://registry.yarnpkg.com/level-js/-/level-js-2.2.4.tgz#bc055f4180635d4489b561c9486fa370e8c11697" - integrity sha1-vAVfQYBjXUSJtWHJSG+jcOjBFpc= - dependencies: - abstract-leveldown "~0.12.0" - idb-wrapper "^1.5.0" - isbuffer "~0.0.0" - ltgt "^2.1.2" - typedarray-to-buffer "~1.0.0" - xtend "~2.1.2" - -level-peek@1.0.6, level-peek@^1.0.6: - version "1.0.6" - resolved "https://registry.yarnpkg.com/level-peek/-/level-peek-1.0.6.tgz#bec51c72a82ee464d336434c7c876c3fcbcce77f" - integrity sha1-vsUccqgu5GTTNkNMfIdsP8vM538= - dependencies: - level-fix-range "~1.0.2" - -level-sublevel@^5.2.0: - version "5.2.3" - resolved "https://registry.yarnpkg.com/level-sublevel/-/level-sublevel-5.2.3.tgz#744c12c72d2e72be78dde3b9b5cd84d62191413a" - integrity sha1-dEwSxy0ucr543eO5tc2E1iGRQTo= - dependencies: - level-fix-range "2.0" - level-hooks ">=4.4.0 <5" - string-range "~1.2.1" - xtend "~2.0.4" - -levelup@^0.18.2: - version "0.18.6" - resolved "https://registry.yarnpkg.com/levelup/-/levelup-0.18.6.tgz#e6a01cb089616c8ecc0291c2a9bd3f0c44e3e5eb" - integrity sha1-5qAcsIlhbI7MApHCqb0/DETj5es= - dependencies: - bl "~0.8.1" - deferred-leveldown "~0.2.0" - errno "~0.1.1" - prr "~0.0.0" - readable-stream "~1.0.26" - semver "~2.3.1" - xtend "~3.0.0" - leven@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/leven/-/leven-3.1.0.tgz#77891de834064cccba82ae7842bb6b14a13ed7f2" @@ -6015,11 +5853,6 @@ lsmod@1.0.0: resolved "https://registry.yarnpkg.com/lsmod/-/lsmod-1.0.0.tgz#9a00f76dca36eb23fa05350afe1b585d4299e64b" integrity sha1-mgD3bco26yP6BTUK/htYXUKZ5ks= -ltgt@^2.1.2: - version "2.2.1" - resolved "https://registry.yarnpkg.com/ltgt/-/ltgt-2.2.1.tgz#f35ca91c493f7b73da0e07495304f17b31f87ee5" - integrity sha1-81ypHEk/e3PaDgdJUwTxezH4fuU= - magic-string@0.25.1: version "0.25.1" resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.25.1.tgz#b1c248b399cd7485da0fe7385c2fc7011843266e" @@ -6474,20 +6307,6 @@ object-keys@^1.0.12, object-keys@^1.1.1: resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.1.tgz#1c47f272df277f3b1daf061677d9c82e2322c60e" integrity sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA== -object-keys@~0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-0.2.0.tgz#cddec02998b091be42bf1035ae32e49f1cb6ea67" - integrity sha1-zd7AKZiwkb5CvxA1rjLknxy26mc= - dependencies: - foreach "~2.0.1" - indexof "~0.0.1" - is "~0.2.6" - -object-keys@~0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-0.4.0.tgz#28a6aae7428dd2c3a92f3d95f21335dd204e0336" - integrity sha1-KKaq50KN0sOpLz2V8hM13SBOAzY= - object-visit@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/object-visit/-/object-visit-1.0.1.tgz#f79c4493af0c5377b59fe39d395e41042dd045bb" @@ -6512,11 +6331,6 @@ object.pick@^1.3.0: dependencies: isobject "^3.0.1" -octal@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/octal/-/octal-1.0.0.tgz#63e7162a68efbeb9e213588d58e989d1e5c4530b" - integrity sha1-Y+cWKmjvvrniE1iNWOmJ0eXEUws= - offset-sourcemap-lines@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/offset-sourcemap-lines/-/offset-sourcemap-lines-1.0.1.tgz#5854dff74b73fc06efcb61d7b721a8113d99be92" @@ -6983,11 +6797,6 @@ pretty-json-stringify@^0.0.2: resolved "https://registry.yarnpkg.com/pretty-json-stringify/-/pretty-json-stringify-0.0.2.tgz#dc0f1dbeab6bc1ab15f40d4cce4f38b75b17a334" integrity sha1-3A8dvqtrwasV9A1Mzk84t1sXozQ= -process-es6@^0.11.2: - version "0.11.6" - resolved "https://registry.yarnpkg.com/process-es6/-/process-es6-0.11.6.tgz#c6bb389f9a951f82bd4eb169600105bd2ff9c778" - integrity sha1-xrs4n5qVH4K9TrFpYAEFvS/5x3g= - process-nextick-args@~2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" @@ -7016,16 +6825,6 @@ proxy-from-env@^1.1.0: resolved "https://registry.yarnpkg.com/proxy-from-env/-/proxy-from-env-1.1.0.tgz#e102f16ca355424865755d2c9e8ea4f24d58c3e2" integrity sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg== -prr@~0.0.0: - version "0.0.0" - resolved "https://registry.yarnpkg.com/prr/-/prr-0.0.0.tgz#1a84b85908325501411853d0081ee3fa86e2926a" - integrity sha1-GoS4WQgyVQFBGFPQCB7j+obikmo= - -prr@~1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/prr/-/prr-1.0.1.tgz#d3fc114ba06995a45ec6893f484ceb1d78f5f476" - integrity sha1-0/wRS6BplaRexok/SEzrHXj19HY= - ps-list@^7.2.0: version "7.2.0" resolved "https://registry.yarnpkg.com/ps-list/-/ps-list-7.2.0.tgz#3d110e1de8249a4b178c9b1cf2a215d1e4e42fc0" @@ -7238,16 +7037,6 @@ read-pkg@^5.2.0: string_decoder "^1.1.1" util-deprecate "^1.0.1" -readable-stream@^1.0.26-4: - version "1.1.14" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.1.14.tgz#7cf4c54ef648e3813084c636dd2079e166c081d9" - integrity sha1-fPTFTvZI44EwhMY23SB54WbAgdk= - dependencies: - core-util-is "~1.0.0" - inherits "~2.0.1" - isarray "0.0.1" - string_decoder "~0.10.x" - readable-stream@^2.0.0, readable-stream@^2.0.2, readable-stream@^2.0.5, readable-stream@^2.2.2, readable-stream@^2.3.0, readable-stream@^2.3.5, readable-stream@~2.3.3, readable-stream@~2.3.6: version "2.3.7" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.7.tgz#1eca1cf711aef814c04f62252a36a62f6cb23b57" @@ -7261,16 +7050,6 @@ readable-stream@^2.0.0, readable-stream@^2.0.2, readable-stream@^2.0.5, readable string_decoder "~1.1.1" util-deprecate "~1.0.1" -readable-stream@~1.0.26, readable-stream@~1.0.26-4: - version "1.0.34" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-1.0.34.tgz#125820e34bc842d2f2aaafafe4c2916ee32c157c" - integrity sha1-Elgg40vIQtLyqq+v5MKRbuMsFXw= - dependencies: - core-util-is "~1.0.0" - inherits "~2.0.1" - isarray "0.0.1" - string_decoder "~0.10.x" - rechoir@^0.6.2: version "0.6.2" resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.6.2.tgz#85204b54dba82d5742e28c96756ef43af50e3384" @@ -7518,16 +7297,6 @@ rollup-plugin-inject@^3.0.0: magic-string "^0.25.3" rollup-pluginutils "^2.8.1" -rollup-plugin-node-builtins@^2.1.2: - version "2.1.2" - resolved "https://registry.yarnpkg.com/rollup-plugin-node-builtins/-/rollup-plugin-node-builtins-2.1.2.tgz#24a1fed4a43257b6b64371d8abc6ce1ab14597e9" - integrity sha1-JKH+1KQyV7a2Q3HYq8bOGrFFl+k= - dependencies: - browserify-fs "^1.0.0" - buffer-es6 "^4.9.2" - crypto-browserify "^3.11.0" - process-es6 "^0.11.2" - rollup-plugin-node-polyfills@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/rollup-plugin-node-polyfills/-/rollup-plugin-node-polyfills-0.2.1.tgz#53092a2744837164d5b8a28812ba5f3ff61109fd" @@ -7672,11 +7441,6 @@ semver@^7.2.1, semver@^7.3.2: dependencies: lru-cache "^6.0.0" -semver@~2.3.1: - version "2.3.2" - resolved "https://registry.yarnpkg.com/semver/-/semver-2.3.2.tgz#b9848f25d6cf36333073ec9ef8856d42f1233e52" - integrity sha1-uYSPJdbPNjMwc+ye+IVtQvEjPlI= - serialize-javascript@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/serialize-javascript/-/serialize-javascript-4.0.0.tgz#b525e1238489a5ecfc42afacc3fe99e666f4b1aa" @@ -8053,11 +7817,6 @@ string-length@^4.0.1: char-regex "^1.0.2" strip-ansi "^6.0.0" -string-range@~1.2, string-range@~1.2.1: - version "1.2.2" - resolved "https://registry.yarnpkg.com/string-range/-/string-range-1.2.2.tgz#a893ed347e72299bc83befbbf2a692a8d239d5dd" - integrity sha1-qJPtNH5yKZvIO++78qaSqNI51d0= - string-width@^3.0.0, string-width@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/string-width/-/string-width-3.1.0.tgz#22767be21b62af1081574306f69ac51b62203961" @@ -8099,11 +7858,6 @@ string_decoder@^1.1.1: dependencies: safe-buffer "~5.2.0" -string_decoder@~0.10.x: - version "0.10.31" - resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" - integrity sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ= - string_decoder@~1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" @@ -8583,11 +8337,6 @@ typedarray-to-buffer@^3.1.5: dependencies: is-typedarray "^1.0.0" -typedarray-to-buffer@~1.0.0: - version "1.0.4" - resolved "https://registry.yarnpkg.com/typedarray-to-buffer/-/typedarray-to-buffer-1.0.4.tgz#9bb8ba0e841fb3f4cf1fe7c245e9f3fa8a5fe99c" - integrity sha1-m7i6DoQfs/TPH+fCRenz+opf6Zw= - typedarray@^0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" @@ -9027,36 +8776,11 @@ xmlchars@^2.2.0: resolved "https://registry.yarnpkg.com/xmlchars/-/xmlchars-2.2.0.tgz#060fe1bcb7f9c76fe2a17db86a9bc3ab894210cb" integrity sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw== -xtend@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/xtend/-/xtend-2.2.0.tgz#eef6b1f198c1c8deafad8b1765a04dad4a01c5a9" - integrity sha1-7vax8ZjByN6vrYsXZaBNrUoBxak= - xtend@^4.0.0, xtend@^4.0.1, xtend@^4.0.2, xtend@~4.0.1: version "4.0.2" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== -xtend@~2.0.4: - version "2.0.6" - resolved "https://registry.yarnpkg.com/xtend/-/xtend-2.0.6.tgz#5ea657a6dba447069c2e59c58a1138cb0c5e6cee" - integrity sha1-XqZXptukRwacLlnFihE4ywxebO4= - dependencies: - is-object "~0.1.2" - object-keys "~0.2.0" - -xtend@~2.1.2: - version "2.1.2" - resolved "https://registry.yarnpkg.com/xtend/-/xtend-2.1.2.tgz#6efecc2a4dad8e6962c4901b337ce7ba87b5d28b" - integrity sha1-bv7MKk2tjmlixJAbM3znuoe10os= - dependencies: - object-keys "~0.4.0" - -xtend@~3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/xtend/-/xtend-3.0.0.tgz#5cce7407baf642cba7becda568111c493f59665a" - integrity sha1-XM50B7r2Qsunvs2laBEcST9ZZlo= - y18n@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/y18n/-/y18n-4.0.1.tgz#8db2b83c31c5d75099bb890b23f3094891e247d4" From bc23310d87bbb90253ffea7454f98533f9980cd2 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Wed, 7 Jul 2021 14:10:42 -0700 Subject: [PATCH 06/36] clean up build bundle file --- build/build-bundle.js | 142 ++++++++------------------------------ lighthouse-core/runner.js | 2 +- package.json | 4 -- yarn.lock | 122 +++----------------------------- 4 files changed, 41 insertions(+), 229 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index 5dbecd5c1f30..fa00738f44c6 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -14,10 +14,19 @@ const fs = require('fs'); const path = require('path'); const assert = require('assert').strict; const mkdir = fs.promises.mkdir; +const rollup = require('rollup'); +const alias = require('@rollup/plugin-alias'); +const commonjs = +// @ts-expect-error types are wrong. +/** @type {import('rollup-plugin-commonjs').default} */ (require('rollup-plugin-commonjs')); +const json = require('@rollup/plugin-json'); +const nodePolyfills = require('rollup-plugin-node-polyfills'); +const nodeResolve = require('rollup-plugin-node-resolve'); +const postprocess = require('./rollup-postprocess.js'); +const replace = require('rollup-plugin-replace'); +const shim = require('rollup-plugin-shim'); +const {terser} = require('rollup-plugin-terser'); const LighthouseRunner = require('../lighthouse-core/runner.js'); -const exorcist = require('exorcist'); -const browserify = require('browserify'); -const terser = require('terser'); const {minifyFileTransform} = require('./build-utils.js'); const Runner = require('../lighthouse-core/runner.js'); const rollupBrfs = require('./rollup-brfs.js'); @@ -27,15 +36,6 @@ const COMMIT_HASH = require('child_process') .execSync('git rev-parse HEAD') .toString().trim(); -const audits = LighthouseRunner.getAuditList() - .map(f => './lighthouse-core/audits/' + f.replace(/\.js$/, '')); - -const gatherers = LighthouseRunner.getGathererList() - .map(f => './lighthouse-core/gather/gatherers/' + f.replace(/\.js$/, '')); - -const locales = fs.readdirSync(LH_ROOT + '/lighthouse-core/lib/i18n/locales/') - .map(f => require.resolve(`../lighthouse-core/lib/i18n/locales/${f}`)); - // HACK: manually include the lighthouse-plugin-publisher-ads audits. /** @type {Array} */ // @ts-expect-error @@ -50,93 +50,12 @@ const isLightrider = file => path.basename(file).includes('lightrider'); // Set to true for source maps. const DEBUG = false; -/** - * Browserify starting at the file at entryPath. Contains entry-point-specific - * ignores (e.g. for DevTools or the extension) to trim the bundle depending on - * the eventual use case. - * @param {string} entryPath - * @param {string} distPath - * @return {Promise} - */ -async function browserifyFile(entryPath, distPath) { - let bundle = browserify(entryPath, {debug: DEBUG}); - - bundle - .plugin('browserify-banner', { - pkg: Object.assign({COMMIT_HASH}, require('../package.json')), - file: require.resolve('./banner.txt'), - }) - // Transform the fs.readFile etc into inline strings. - .transform('@wardpeet/brfs', { - readFileSyncTransform: minifyFileTransform, - global: true, - parserOpts: {ecmaVersion: 12}, - }) - // Strip everything out of package.json includes except for the version. - .transform('package-json-versionify'); - - // scripts will need some additional transforms, ignores and requires… - bundle.ignore('source-map') - .ignore('debug/node') - .ignore('intl') - .ignore('intl-pluralrules') - .ignore('raven') - .ignore('pako/lib/zlib/inflate.js'); - - // Don't include the desktop protocol connection. - bundle.ignore(require.resolve('../lighthouse-core/gather/connections/cri.js')); - - // Don't include the stringified report in DevTools - see devtools-report-assets.js - // Don't include in Lightrider - HTML generation isn't supported, so report assets aren't needed. - if (isDevtools(entryPath) || isLightrider(entryPath)) { - bundle.ignore(require.resolve('../report/report-assets.js')); - } - - // Don't include locales in DevTools. - if (isDevtools(entryPath)) { - // @ts-expect-error bundle.ignore does accept an array of strings. - bundle.ignore(locales); - } - - // Expose the audits, gatherers, and computed artifacts so they can be dynamically loaded. - // Exposed path must be a relative path from lighthouse-core/config/config-helpers.js (where loading occurs). - const corePath = './lighthouse-core/'; - const driverPath = `${corePath}gather/`; - audits.forEach(audit => { - bundle = bundle.require(audit, {expose: audit.replace(corePath, '../')}); - }); - gatherers.forEach(gatherer => { - bundle = bundle.require(gatherer, {expose: gatherer.replace(driverPath, '../gather/')}); - }); - - // HACK: manually include the lighthouse-plugin-publisher-ads audits. - if (isDevtools(entryPath) || isLightrider(entryPath)) { - bundle.require('lighthouse-plugin-publisher-ads'); - pubAdsAudits.forEach(pubAdAudit => { - bundle = bundle.require(pubAdAudit); - }); - } - - // browerify's url shim doesn't work with .URL in node_modules, - // and within robots-parser, it does `var URL = require('url').URL`, so we expose our own. - // @see https://github.com/GoogleChrome/lighthouse/issues/5273 - const pathToURLShim = require.resolve('../lighthouse-core/lib/url-shim.js'); - bundle = bundle.require(pathToURLShim, {expose: 'url'}); - - let bundleStream = bundle.bundle(); - - // Make sure path exists. - await mkdir(path.dirname(distPath), {recursive: true}); - return new Promise((resolve, reject) => { - const writeStream = fs.createWriteStream(distPath); - writeStream.on('finish', resolve); - writeStream.on('error', reject); - - // Extract the inline source map to an external file. - if (DEBUG) bundleStream = bundleStream.pipe(exorcist(`${distPath}.map`)); - bundleStream.pipe(writeStream); - }); -} +// TODO +// bundle +// .plugin('browserify-banner', { +// pkg: Object.assign({COMMIT_HASH}, require('../package.json')), +// file: require.resolve('./banner.txt'), +// }) /** * Minify a javascript file, in place. @@ -185,12 +104,6 @@ async function minifyScript(filePath) { * @return {Promise} */ async function build(entryPath, distPath) { - const rollup = require('rollup'); - const {terser} = require('rollup-plugin-terser'); - const commonjs = - // @ts-expect-error types are wrong. - /** @type {import('rollup-plugin-commonjs').default} */ (require('rollup-plugin-commonjs')); - // List of paths (absolute / relative to config-helpers.js) to include // in bundle and make accessible via config-helpers.js `requireWrapper`. const dynamicModulePaths = [ @@ -240,12 +153,14 @@ async function build(entryPath, distPath) { shimsObj[modulePath] = 'export default {}'; } + const packageJsonShim = {version: require('../package.json').version}; + shimsObj[require.resolve('../package.json')] = `export default ${JSON.stringify(packageJsonShim)}`; + const bundle = await rollup.rollup({ input: entryPath, context: 'globalThis', plugins: [ - require('@rollup/plugin-json')(), - require('rollup-plugin-replace')({ + replace({ delimiters: ['', ''], values: { '/* BUILD_REPLACE_BUNDLED_MODULES */': `[\n${bundledMapEntriesCode},\n]`, @@ -253,13 +168,13 @@ async function build(entryPath, distPath) { '__filename': (id) => `'${path.relative(LH_ROOT, id)}'`, }, }), - require('@rollup/plugin-alias')({ + alias({ entries: { debug: require.resolve('debug/src/browser.js'), url: require.resolve('../lighthouse-core/lib/url-shim.js'), }, }), - require('rollup-plugin-shim')({ + shim({ ...shimsObj, // Allows for plugins to import lighthouse. 'lighthouse': `import Audit from '${require.resolve('../lighthouse-core/audits/audit.js')}'; export {Audit};`, @@ -275,13 +190,16 @@ async function build(entryPath, distPath) { // https://github.com/rollup/plugins/issues/922 ignoreGlobal: true, }), - require('rollup-plugin-node-resolve')({preferBuiltins: true}), - require('rollup-plugin-node-polyfills')(), + json({ + preferConst: true, + }), + nodeResolve({preferBuiltins: true}), + nodePolyfills(), // Rollup sees the usages of these functions in page functions (ex: see AnchorElements) // and treats them as globals. Because the names are "taken" by the global, Rollup renames // the actual functions (getNodeDetails$1). The page functions expect a certain name, so // here we undo what Rollup did. - require('./rollup-postprocess.js')([ + postprocess([ [/getElementsInDocument\$1/, 'getElementsInDocument'], [/getNodeDetails\$1/, 'getNodeDetails'], [/getRectCenterPoint\$1/, 'getRectCenterPoint'], diff --git a/lighthouse-core/runner.js b/lighthouse-core/runner.js index 82c35c57e92a..77c0d28fe325 100644 --- a/lighthouse-core/runner.js +++ b/lighthouse-core/runner.js @@ -20,6 +20,7 @@ const URL = require('./lib/url-shim.js'); const Sentry = require('./lib/sentry.js'); const generateReport = require('../report/report-generator.js').generateReport; const LHError = require('./lib/lh-error.js'); +const {version: lighthouseVersion} = require('../package.json'); /** @typedef {import('./gather/connections/connection.js')} Connection */ /** @typedef {import('./lib/arbitrary-equality-map.js')} ArbitraryEqualityMap */ @@ -112,7 +113,6 @@ class Runner { } // Entering: conclusion of the lighthouse result object - const lighthouseVersion = require('../package.json').version; // Use version from gathering stage. // If accessibility gatherer didn't run or errored, it won't be in credits. diff --git a/package.json b/package.json index e2111473f985..e0439a6097bd 100644 --- a/package.json +++ b/package.json @@ -102,7 +102,6 @@ "@types/cpy": "^5.1.0", "@types/css-font-loading-module": "^0.0.2", "@types/eslint": "^4.16.6", - "@types/exorcist": "^0.4.5", "@types/gh-pages": "^2.0.0", "@types/google.analytics": "0.0.39", "@types/jest": "^24.0.9", @@ -126,7 +125,6 @@ "angular": "^1.7.4", "archiver": "^3.0.0", "browserify": "^17.0.0", - "browserify-banner": "^1.0.15", "bundle-phobia-cli": "^0.14.6", "c8": "^7.4.0", "chalk": "^2.4.1", @@ -140,7 +138,6 @@ "eslint-config-google": "^0.9.1", "eslint-plugin-local-rules": "0.1.0", "event-target-shim": "^6.0.2", - "exorcist": "^1.0.1", "gh-pages": "^2.0.1", "glob": "^7.1.3", "idb-keyval": "2.2.0", @@ -153,7 +150,6 @@ "mime-types": "^2.1.30", "node-fetch": "^2.6.1", "npm-run-posix-or-windows": "^2.0.2", - "package-json-versionify": "^1.0.4", "pako": "^2.0.3", "pretty-json-stringify": "^0.0.2", "puppeteer": "^9.1.1", diff --git a/yarn.lock b/yarn.lock index 78342e3419b6..20fcd1571f33 100644 --- a/yarn.lock +++ b/yarn.lock @@ -935,13 +935,6 @@ resolved "https://registry.yarnpkg.com/@types/events/-/events-1.2.0.tgz#81a6731ce4df43619e5c8c945383b3e62a89ea86" integrity sha512-KEIlhXnIutzKwRbQkGWb/I4HFqBuUykAdHgDED6xqwXJfONCjF5VoE0cXEiurh3XauygxzeDzgtXUqvLkxFzzA== -"@types/exorcist@^0.4.5": - version "0.4.5" - resolved "https://registry.yarnpkg.com/@types/exorcist/-/exorcist-0.4.5.tgz#613244b12490f5108f808589bc12b28450264eb8" - integrity sha1-YTJEsSSQ9RCPgIWJvBKyhFAmTrg= - dependencies: - "@types/through" "*" - "@types/filesystem@*": version "0.0.28" resolved "https://registry.yarnpkg.com/@types/filesystem/-/filesystem-0.0.28.tgz#3fd7735830f2c7413cb5ac45780bc45904697b0e" @@ -1136,13 +1129,6 @@ resolved "https://registry.yarnpkg.com/@types/tabulator-tables/-/tabulator-tables-4.9.1.tgz#4fbc5465960598308260f50f840d610bcc8ffa3a" integrity sha512-BfHDeVDfLF5H0HYFQ3ZEfv7J43sD8dw8fhci8juRB5uc0xQWboDd6f1hgLOwQioYhO9vWZEAWfuD6c1wl9qzmw== -"@types/through@*": - version "0.0.29" - resolved "https://registry.yarnpkg.com/@types/through/-/through-0.0.29.tgz#72943aac922e179339c651fa34a4428a4d722f93" - integrity sha512-9a7C5VHh+1BKblaYiq+7Tfc+EOmjMdZaD1MYtkQjSoxgB69tBjW98ry6SKsi4zEIWztLOMRuL87A3bdT/Fc/4w== - dependencies: - "@types/node" "*" - "@types/update-notifier@^4.1.0": version "4.1.0" resolved "https://registry.yarnpkg.com/@types/update-notifier/-/update-notifier-4.1.0.tgz#891502c741babf12a666fa9ceb3af011dd76893c" @@ -1833,18 +1819,6 @@ browserify-aes@^1.0.0, browserify-aes@^1.0.4: inherits "^2.0.1" safe-buffer "^5.0.1" -browserify-banner@^1.0.15: - version "1.0.15" - resolved "https://registry.yarnpkg.com/browserify-banner/-/browserify-banner-1.0.15.tgz#cd9f252472974781de96b4fef07d67c9ce308700" - integrity sha512-xXmWMFn9nBl93m56czUOGxIi5DDV6fZy8+N6NhZhgoYGSNZLjJ/9cwfgLR50S4rB+hTSooWONO4a38Q0zYOwFA== - dependencies: - convert-source-map "^1.6.0" - lodash "^4.17.15" - moment "^2.24.0" - offset-sourcemap-lines "^1.0.1" - ono "^5.0.2" - through2 "^3.0.1" - browserify-cipher@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/browserify-cipher/-/browserify-cipher-1.0.1.tgz#8d6474c1b870bfdabcd3bcfcc1934a10e94f15f0" @@ -1864,11 +1838,6 @@ browserify-des@^1.0.0: inherits "^2.0.1" safe-buffer "^5.1.2" -browserify-package-json@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/browserify-package-json/-/browserify-package-json-1.0.1.tgz#98dde8aa5c561fd6d3fe49bbaa102b74b396fdea" - integrity sha1-mN3oqlxWH9bT/km7qhArdLOW/eo= - browserify-rsa@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/browserify-rsa/-/browserify-rsa-4.0.1.tgz#21e0abfaf6f2029cf2fafb133567a701d4135524" @@ -2654,7 +2623,7 @@ conventional-commits-parser@^2.0.0: through2 "^2.0.0" trim-off-newlines "^1.0.0" -convert-source-map@^1.1.0, convert-source-map@^1.4.0, convert-source-map@^1.5.1, convert-source-map@^1.6.0, convert-source-map@^1.7.0: +convert-source-map@^1.4.0, convert-source-map@^1.5.1, convert-source-map@^1.6.0, convert-source-map@^1.7.0: version "1.7.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.7.0.tgz#17a2cb882d7f77d3490585e2ce6c524424a3a442" integrity sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA== @@ -3554,16 +3523,6 @@ exit@^0.1.2: resolved "https://registry.yarnpkg.com/exit/-/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c" integrity sha1-BjJjj42HfMghB9MKD/8aF8uhzQw= -exorcist@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/exorcist/-/exorcist-1.0.1.tgz#79316e3c4885845490f7bb405c0e5b5db1167c52" - integrity sha1-eTFuPEiFhFSQ97tAXA5bXbEWfFI= - dependencies: - is-stream "~1.1.0" - minimist "0.0.5" - mkdirp "~0.5.1" - mold-source-map "~0.4.0" - expand-brackets@^2.1.4: version "2.1.4" resolved "https://registry.yarnpkg.com/expand-brackets/-/expand-brackets-2.1.4.tgz#b77735e315ce30f6b6eff0f83b04151a22449622" @@ -4807,11 +4766,6 @@ is-stream@^2.0.0: resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.0.tgz#bde9c32680d6fae04129d6ac9d921ce7815f78e3" integrity sha512-XCoy+WlUr7d1+Z8GgSuXmpuUFC9fOhRXglJMx+dwLKTkL44Cjd4W1Z5P+BQZpr+cR93aGP4S/s7Ftw6Nd/kiEw== -is-stream@~1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" - integrity sha1-EtSj3U5o4Lec6428hBc66A2RykQ= - is-string@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/is-string/-/is-string-1.0.5.tgz#40493ed198ef3ff477b8c7f92f644ec82a5cd3a6" @@ -6044,11 +5998,6 @@ minimatch@^3.0.4: dependencies: brace-expansion "^1.1.7" -minimist@0.0.5: - version "0.0.5" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.5.tgz#d7aa327bcecf518f9106ac6b8f003fa3bcea8566" - integrity sha1-16oye87PUY+RBqxrjwA/o7zqhWY= - minimist@^1.1.0, minimist@^1.1.1, minimist@^1.1.3, minimist@^1.2.0, minimist@^1.2.5: version "1.2.5" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" @@ -6067,13 +6016,6 @@ mkdirp-classic@^0.5.2: resolved "https://registry.yarnpkg.com/mkdirp-classic/-/mkdirp-classic-0.5.3.tgz#fa10c9115cc6d8865be221ba47ee9bed78601113" integrity sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A== -mkdirp@~0.5.1: - version "0.5.5" - resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.5.tgz#d91cefd62d1436ca0f41620e251288d420099def" - integrity sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ== - dependencies: - minimist "^1.2.5" - modify-values@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/modify-values/-/modify-values-1.0.0.tgz#e2b6cdeb9ce19f99317a53722f3dbf5df5eaaab2" @@ -6100,19 +6042,6 @@ module-deps@^6.2.3: through2 "^2.0.0" xtend "^4.0.0" -mold-source-map@~0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/mold-source-map/-/mold-source-map-0.4.0.tgz#cf67e0b31c47ab9badb5c9c25651862127bb8317" - integrity sha1-z2fgsxxHq5uttcnCVlGGISe7gxc= - dependencies: - convert-source-map "^1.1.0" - through "~2.2.7" - -moment@^2.24.0: - version "2.24.0" - resolved "https://registry.yarnpkg.com/moment/-/moment-2.24.0.tgz#0d055d53f5052aa653c9f6eb68bb5d12bf5c2b5b" - integrity sha512-bV7f+6l2QigeBBZSM/6yTNq4P2fNpSWj/0e7jQcy87A8e7o2nAfP/34/2ky5Vw4B9S446EtIhodAzkFCcR4dQg== - ms@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" @@ -6331,13 +6260,6 @@ object.pick@^1.3.0: dependencies: isobject "^3.0.1" -offset-sourcemap-lines@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/offset-sourcemap-lines/-/offset-sourcemap-lines-1.0.1.tgz#5854dff74b73fc06efcb61d7b721a8113d99be92" - integrity sha1-WFTf90tz/Abvy2HXtyGoET2ZvpI= - dependencies: - source-map "^0.5.0" - once@^1.3.0, once@^1.3.1, once@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" @@ -6359,11 +6281,6 @@ onetime@^5.1.2: dependencies: mimic-fn "^2.1.0" -ono@^5.0.2: - version "5.1.0" - resolved "https://registry.yarnpkg.com/ono/-/ono-5.1.0.tgz#8cafa7e56afa2211ad63dd2eb798427e64f1a070" - integrity sha512-GgqRIUWErLX4l9Up0khRtbrlH8Fyj59A0nKv8V6pWEto38aUgnOGOOF7UmgFFLzFnDSc8REzaTXOc0hqEe7yIw== - open@^6.4.0: version "6.4.0" resolved "https://registry.yarnpkg.com/open/-/open-6.4.0.tgz#5c13e96d0dc894686164f18965ecfe889ecfc8a9" @@ -6489,13 +6406,6 @@ p-try@^2.0.0: resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.0.0.tgz#85080bb87c64688fa47996fe8f7dfbe8211760b1" integrity sha512-hMp0onDKIajHfIkdRk3P4CdCmErkYAxxDtP3Wx/4nZ3aGlau2VKh3mZpcuFkH27WQkL/3WBCPOktzA9ZOAnMQQ== -package-json-versionify@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/package-json-versionify/-/package-json-versionify-1.0.4.tgz#5860587a944873a6b7e6d26e8e51ffb22315bf17" - integrity sha1-WGBYepRIc6a35tJujlH/siMVvxc= - dependencies: - browserify-package-json "^1.0.0" - package-json@^6.3.0: version "6.5.0" resolved "https://registry.yarnpkg.com/package-json/-/package-json-6.5.0.tgz#6feedaca35e75725876d0b0e64974697fed145b0" @@ -7028,15 +6938,6 @@ read-pkg@^5.2.0: parse-json "^5.0.0" type-fest "^0.6.0" -"readable-stream@2 || 3", readable-stream@^3.1.1, readable-stream@^3.4.0, readable-stream@^3.5.0, readable-stream@^3.6.0: - version "3.6.0" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.0.tgz#337bbda3adc0706bd3e024426a286d4b4b2c9198" - integrity sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA== - dependencies: - inherits "^2.0.3" - string_decoder "^1.1.1" - util-deprecate "^1.0.1" - readable-stream@^2.0.0, readable-stream@^2.0.2, readable-stream@^2.0.5, readable-stream@^2.2.2, readable-stream@^2.3.0, readable-stream@^2.3.5, readable-stream@~2.3.3, readable-stream@~2.3.6: version "2.3.7" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.7.tgz#1eca1cf711aef814c04f62252a36a62f6cb23b57" @@ -7050,6 +6951,15 @@ readable-stream@^2.0.0, readable-stream@^2.0.2, readable-stream@^2.0.5, readable string_decoder "~1.1.1" util-deprecate "~1.0.1" +readable-stream@^3.1.1, readable-stream@^3.4.0, readable-stream@^3.5.0, readable-stream@^3.6.0: + version "3.6.0" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.0.tgz#337bbda3adc0706bd3e024426a286d4b4b2c9198" + integrity sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA== + dependencies: + inherits "^2.0.3" + string_decoder "^1.1.1" + util-deprecate "^1.0.1" + rechoir@^0.6.2: version "0.6.2" resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.6.2.tgz#85204b54dba82d5742e28c96756ef43af50e3384" @@ -8111,23 +8021,11 @@ through2@^2.0.0, through2@^2.0.2, through2@~2.0.3: readable-stream "~2.3.6" xtend "~4.0.1" -through2@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/through2/-/through2-3.0.1.tgz#39276e713c3302edf9e388dd9c812dd3b825bd5a" - integrity sha512-M96dvTalPT3YbYLaKaCuwu+j06D/8Jfib0o/PxbVt6Amhv3dUAtW6rTV1jPgJSBG83I/e04Y6xkVdVhSRhi0ww== - dependencies: - readable-stream "2 || 3" - through@2, "through@>=2.2.7 <3", through@^2.3.6, through@^2.3.8: version "2.3.8" resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" integrity sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= -through@~2.2.7: - version "2.2.7" - resolved "https://registry.yarnpkg.com/through/-/through-2.2.7.tgz#6e8e21200191d4eb6a99f6f010df46aa1c6eb2bd" - integrity sha1-bo4hIAGR1OtqmfbwEN9Gqhxusr0= - timed-out@4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/timed-out/-/timed-out-4.0.1.tgz#f32eacac5a175bea25d7fab565ab3ed8741ef56f" From b3d90371658819edd650dee7f85a6034f6a5a057 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Wed, 7 Jul 2021 15:10:28 -0700 Subject: [PATCH 07/36] banner --- build/banner.txt | 7 -- build/build-bundle.js | 128 +++++++++++++++--------------- build/build-lightrider-bundles.js | 2 +- package.json | 5 +- 4 files changed, 66 insertions(+), 76 deletions(-) delete mode 100644 build/banner.txt diff --git a/build/banner.txt b/build/banner.txt deleted file mode 100644 index 49f4660c541c..000000000000 --- a/build/banner.txt +++ /dev/null @@ -1,7 +0,0 @@ -<%= _.startCase(pkg.name) %> v<%= pkg.version %> <%= pkg.COMMIT_HASH %> (<%= moment().format('MMMM Do YYYY') %>) - -<%= pkg.description %> - -@homepage <%= pkg.homepage %> -@author <%= pkg.author %> -@license <%= pkg.license %> diff --git a/build/build-bundle.js b/build/build-bundle.js index fa00738f44c6..adff3dc37697 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -10,23 +10,29 @@ * in the browser (as long as they have access to a debugger protocol Connection). */ -const fs = require('fs'); +/** + * Rollup plugins don't export types that work with commonjs. + * @template T + * @param {T} module + * @return {T['default']} + */ +function rollupPluginTypeCoerce(module) { + // @ts-expect-error + return module; +} + const path = require('path'); -const assert = require('assert').strict; -const mkdir = fs.promises.mkdir; const rollup = require('rollup'); -const alias = require('@rollup/plugin-alias'); -const commonjs = -// @ts-expect-error types are wrong. -/** @type {import('rollup-plugin-commonjs').default} */ (require('rollup-plugin-commonjs')); -const json = require('@rollup/plugin-json'); -const nodePolyfills = require('rollup-plugin-node-polyfills'); -const nodeResolve = require('rollup-plugin-node-resolve'); -const postprocess = require('./rollup-postprocess.js'); -const replace = require('rollup-plugin-replace'); +const alias = rollupPluginTypeCoerce(require('@rollup/plugin-alias')); +const commonjs = rollupPluginTypeCoerce(require('rollup-plugin-commonjs')); +const json = rollupPluginTypeCoerce(require('@rollup/plugin-json')); +const nodePolyfills = rollupPluginTypeCoerce(require('rollup-plugin-node-polyfills')); +const nodeResolve = rollupPluginTypeCoerce(require('rollup-plugin-node-resolve')); +const replace = rollupPluginTypeCoerce(require('rollup-plugin-replace')); +// @ts-expect-error: no types const shim = require('rollup-plugin-shim'); const {terser} = require('rollup-plugin-terser'); -const LighthouseRunner = require('../lighthouse-core/runner.js'); +const postprocess = require('./rollup-postprocess.js'); const {minifyFileTransform} = require('./build-utils.js'); const Runner = require('../lighthouse-core/runner.js'); const rollupBrfs = require('./rollup-brfs.js'); @@ -50,60 +56,34 @@ const isLightrider = file => path.basename(file).includes('lightrider'); // Set to true for source maps. const DEBUG = false; -// TODO -// bundle -// .plugin('browserify-banner', { -// pkg: Object.assign({COMMIT_HASH}, require('../package.json')), -// file: require.resolve('./banner.txt'), -// }) - +const pkg = require('../package.json'); +const today = (() => { + const date = new Date(); + const year = new Intl.DateTimeFormat('en', {year: 'numeric'}).format(date); + const month = new Intl.DateTimeFormat('en', {month: 'short'}).format(date); + const day = new Intl.DateTimeFormat('en', {day: '2-digit'}).format(date); + return `${month} ${day} ${year}`; +})(); +const banner = ` /** - * Minify a javascript file, in place. - * @param {string} filePath + * Lighthouse v${pkg.version} ${COMMIT_HASH} (${today}) + * + * ${pkg.description} + * + * @homepage ${pkg.homepage} + * @author ${pkg.author} + * @license ${pkg.license} */ -async function minifyScript(filePath) { - const code = fs.readFileSync(filePath, 'utf-8'); - const result = await terser.minify(code, { - ecma: 2019, - output: { - comments: /^!/, - max_line_len: 1000, - }, - // The config relies on class names for gatherers. - keep_classnames: true, - // Runtime.evaluate errors if function names are elided. - keep_fnames: true, - sourceMap: DEBUG && { - content: JSON.parse(fs.readFileSync(`${filePath}.map`, 'utf-8')), - url: path.basename(`${filePath}.map`), - }, - }); - - // Add the banner and modify globals for DevTools if necessary. - if (isDevtools(filePath) && result.code) { - // Add a comment for TypeScript, but not if in DEBUG mode so that source maps are not affected. - // See lighthouse-cli/test/smokehouse/lighthouse-runners/bundle.js - if (!DEBUG) { - result.code = - '// @ts-nocheck - Prevent tsc stepping into any required bundles.\n' + result.code; - } - - assert.ok(result.code.includes('\nrequire='), 'missing browserify require stub'); - result.code = result.code.replace('\nrequire=', '\nglobalThis.require='); - assert.ok(!result.code.includes('\nrequire='), 'contained unexpected browserify require stub'); - } - - fs.writeFileSync(filePath, result.code); - if (DEBUG) fs.writeFileSync(`${filePath}.map`, result.map); -} +`.trim(); /** * Browserify starting at entryPath, writing the minified result to distPath. * @param {string} entryPath * @param {string} distPath + * @param {{minify: boolean}=} opts * @return {Promise} */ -async function build(entryPath, distPath) { +async function build(entryPath, distPath, opts = {minify: true}) { // List of paths (absolute / relative to config-helpers.js) to include // in bundle and make accessible via config-helpers.js `requireWrapper`. const dynamicModulePaths = [ @@ -124,6 +104,7 @@ async function build(entryPath, distPath) { return `['${pathNoExt}', require('${modulePath}')]`; }).join(',\n'); + /** @type {Record} */ const shimsObj = {}; const modulesToIgnore = [ 'intl-pluralrules', @@ -144,6 +125,7 @@ async function build(entryPath, distPath) { // Don't include locales in DevTools. if (isDevtools(entryPath)) { const localeKeys = Object.keys(require('../lighthouse-core/lib/i18n/locales.js')); + /** @type {Record} */ const localesShim = {}; for (const key of localeKeys) localesShim[key] = {}; shimsObj['./locales.js'] = `export default ${JSON.stringify(localesShim)}`; @@ -154,7 +136,8 @@ async function build(entryPath, distPath) { } const packageJsonShim = {version: require('../package.json').version}; - shimsObj[require.resolve('../package.json')] = `export default ${JSON.stringify(packageJsonShim)}`; + shimsObj[require.resolve('../package.json')] = + `export default ${JSON.stringify(packageJsonShim)}`; const bundle = await rollup.rollup({ input: entryPath, @@ -177,7 +160,10 @@ async function build(entryPath, distPath) { shim({ ...shimsObj, // Allows for plugins to import lighthouse. - 'lighthouse': `import Audit from '${require.resolve('../lighthouse-core/audits/audit.js')}'; export {Audit};`, + 'lighthouse': ` + import Audit from '${require.resolve('../lighthouse-core/audits/audit.js')}'; + export {Audit}; + `, }), // Currently must run before commonjs (brfs does not support import). // This currenty messes up source maps. @@ -190,9 +176,7 @@ async function build(entryPath, distPath) { // https://github.com/rollup/plugins/issues/922 ignoreGlobal: true, }), - json({ - preferConst: true, - }), + json(), nodeResolve({preferBuiltins: true}), nodePolyfills(), // Rollup sees the usages of these functions in page functions (ex: see AnchorElements) @@ -204,10 +188,14 @@ async function build(entryPath, distPath) { [/getNodeDetails\$1/, 'getNodeDetails'], [/getRectCenterPoint\$1/, 'getRectCenterPoint'], ]), - terser({ + opts.minify && terser({ ecma: 2019, output: { - comments: /^!/, + comments: (node, comment) => { + const text = comment.value; + if (text.includes('The Lighthouse Authors') && comment.line > 1) return false; + return /@ts-nocheck - Prevent tsc|@preserve|@license|@cc_on/i.test(text); + }, max_line_len: 1000, }, // The config relies on class names for gatherers. @@ -220,6 +208,16 @@ async function build(entryPath, distPath) { await bundle.write({ file: distPath, + banner: () => { + let result = banner; + + // Add the banner and modify globals for DevTools if necessary. + if (isDevtools(entryPath) && !DEBUG) { + result += '\n// @ts-nocheck - Prevent tsc stepping into any required bundles.'; + } + + return result; + }, format: 'iife', sourcemap: DEBUG, }); diff --git a/build/build-lightrider-bundles.js b/build/build-lightrider-bundles.js index 88d376a81ce3..40cc73cd42eb 100644 --- a/build/build-lightrider-bundles.js +++ b/build/build-lightrider-bundles.js @@ -29,7 +29,7 @@ fs.mkdirSync(path.dirname(distDir), {recursive: true}); function buildEntryPoint() { const inFile = `${sourceDir}/${entrySourceName}`; const outFile = `${distDir}/${entryDistName}`; - return bundleBuilder.build(inFile, outFile); + return bundleBuilder.build(inFile, outFile, {minify: false}); } /** diff --git a/package.json b/package.json index e0439a6097bd..b595260c8b32 100644 --- a/package.json +++ b/package.json @@ -19,14 +19,13 @@ "build-extension": "yarn build-extension-chrome && yarn build-extension-firefox", "build-extension-chrome": "node ./build/build-extension.js chrome", "build-extension-firefox": "node ./build/build-extension.js firefox", - "build-devtools": "yarn reset-link && node ./build/build-bundle.js clients/devtools-entry.js dist/lighthouse-dt-bundle.js && node ./build/build-dt-report-resources.js", + "build-devtools": "node ./build/build-bundle.js clients/devtools-entry.js dist/lighthouse-dt-bundle.js && node ./build/build-dt-report-resources.js", "build-smokehouse-bundle": "node ./build/build-smokehouse-bundle.js", - "build-lr": "yarn reset-link && node ./build/build-lightrider-bundles.js", + "build-lr": "node ./build/build-lightrider-bundles.js", "build-pack": "bash build/build-pack.sh", "build-report": "node build/build-report.js", "build-treemap": "node ./build/build-treemap.js", "build-viewer": "node ./build/build-viewer.js", - "reset-link": "(yarn unlink || true) && yarn link && yarn link lighthouse && cd lighthouse-logger && (yarn unlink || true) && yarn link && cd .. && yarn link lighthouse-logger", "c8": "bash lighthouse-core/scripts/c8.sh", "clean": "rm -r dist proto/scripts/*.json proto/scripts/*_pb2.* proto/scripts/*_pb.* proto/scripts/__pycache__ proto/scripts/*.pyc *.report.html *.report.dom.html *.report.json *.devtoolslog.json *.trace.json lighthouse-core/lib/i18n/locales/*.ctc.json || true", "lint": "[ \"$CI\" = true ] && eslint --quiet -f codeframe . || eslint .", From 823c6f588b6850b3d4ff7a01c275367d87648676 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Wed, 7 Jul 2021 16:40:36 -0700 Subject: [PATCH 08/36] working again --- build/build-bundle.js | 7 +++++-- build/build-lightrider-bundles.js | 3 --- build/rollup-brfs.js | 13 ++----------- build/rollup-postprocess.js | 7 +++++++ lighthouse-core/lib/i18n/i18n.js | 2 +- lighthouse-logger/index.js | 14 ++++---------- package.json | 5 +++-- 7 files changed, 22 insertions(+), 29 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index adff3dc37697..bb0651ec2db2 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -149,12 +149,15 @@ async function build(entryPath, distPath, opts = {minify: true}) { '/* BUILD_REPLACE_BUNDLED_MODULES */': `[\n${bundledMapEntriesCode},\n]`, '__dirname': (id) => `'${path.relative(LH_ROOT, path.dirname(id))}'`, '__filename': (id) => `'${path.relative(LH_ROOT, id)}'`, + // This package exports to default in a way that causes Rollup to get confused, + // resulting in MessageFormat being undefined. + 'require(\'intl-messageformat\').default': 'require(\'intl-messageformat\')', }, }), alias({ entries: { - debug: require.resolve('debug/src/browser.js'), - url: require.resolve('../lighthouse-core/lib/url-shim.js'), + 'debug': require.resolve('debug/src/browser.js'), + 'url': require.resolve('../lighthouse-core/lib/url-shim.js'), }, }), shim({ diff --git a/build/build-lightrider-bundles.js b/build/build-lightrider-bundles.js index 40cc73cd42eb..1bf018d1bc3c 100644 --- a/build/build-lightrider-bundles.js +++ b/build/build-lightrider-bundles.js @@ -23,9 +23,6 @@ const entryDistName = 'lighthouse-lr-bundle.js'; fs.mkdirSync(path.dirname(distDir), {recursive: true}); -/** - * Browserify and minify entry point. - */ function buildEntryPoint() { const inFile = `${sourceDir}/${entrySourceName}`; const outFile = `${distDir}/${entryDistName}`; diff --git a/build/rollup-brfs.js b/build/rollup-brfs.js index 9aa96cba33a3..1b5b038790b8 100644 --- a/build/rollup-brfs.js +++ b/build/rollup-brfs.js @@ -5,12 +5,10 @@ */ 'use strict'; - -const {Plugin} = require('rollup'); const path = require('path'); const {Readable} = require('stream'); - const brfs = require('@wardpeet/brfs'); + const EXTENSIONS = ['.js', '.jsx', '.ts', '.tsx']; const rollupBrfs = function rollUpBrfs(options = {}) { @@ -24,11 +22,6 @@ const rollupBrfs = function rollUpBrfs(options = {}) { return new Promise((resolve, reject) => { let output = ''; const src = new Readable(); - // if (id.endsWith('stacks.js')) { - // debugger; - // code = code.replace(/commonjsHelpers\.commonjsRequire\.resolve\(/g, 'require.resolve('); - // code = code.replace(/import fs from '\u0000fs\?commonjs-proxy';/g, "import fs from 'fs';"); - // } src.push(code); src.push(null); const stream = src.pipe(brfs(id, options)); @@ -36,9 +29,6 @@ const rollupBrfs = function rollUpBrfs(options = {}) { output += data.toString(); }); stream.on('end', function() { - // if (id.endsWith('stacks.js')) { - // console.log({id, code}); - // } resolve({ code: output, map: {mappings: ''}, @@ -51,4 +41,5 @@ const rollupBrfs = function rollUpBrfs(options = {}) { }, }; }; + module.exports = rollupBrfs; diff --git a/build/rollup-postprocess.js b/build/rollup-postprocess.js index cf4a061406a6..991e55525f44 100644 --- a/build/rollup-postprocess.js +++ b/build/rollup-postprocess.js @@ -1,3 +1,10 @@ +/** + * @license Copyright 2021 The Lighthouse Authors. All Rights Reserved. + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. + */ +'use strict'; + const MagicString = require('magic-string'); let currentToken; diff --git a/lighthouse-core/lib/i18n/i18n.js b/lighthouse-core/lib/i18n/i18n.js index d9bd82ba950e..977d21a09c8c 100644 --- a/lighthouse-core/lib/i18n/i18n.js +++ b/lighthouse-core/lib/i18n/i18n.js @@ -8,7 +8,7 @@ /** @typedef {import('../../lib/i18n/locales').LhlMessages} LhlMessages */ const path = require('path'); -const MessageFormat = require('intl-messageformat').default || require('intl-messageformat'); +const MessageFormat = require('intl-messageformat').default; const lookupClosestLocale = require('lookup-closest-locale'); const LOCALES = require('./locales.js'); const {isObjectOfUnknownValues, isObjectOrArrayOfUnknownValues} = require('../type-verifiers.js'); diff --git a/lighthouse-logger/index.js b/lighthouse-logger/index.js index 7a70fbe7d078..a8b61cac191e 100644 --- a/lighthouse-logger/index.js +++ b/lighthouse-logger/index.js @@ -5,16 +5,14 @@ */ 'use strict'; -let debug = require('debug'); -const marky = require('marky'); const process = require('process'); - -if (debug.__moduleExports) debug = debug.__moduleExports; +const debug = require('debug'); +const marky = require('marky'); const EventEmitter = require('events').EventEmitter; const isWindows = process.platform === 'win32'; -// process.browser is set when browserify'd via the `process` npm module +// @ts-expect-error: process.browser is set when browserify'd via the `process` npm module const isBrowser = process.browser; const colors = { @@ -27,11 +25,7 @@ const colors = { }; // allow non-red/yellow colors for debug() -try { - debug.colors = [colors.cyan, colors.green, colors.blue, colors.magenta]; -} catch { - // Might be made readonly in rollup bundle. -} +debug.colors = [colors.cyan, colors.green, colors.blue, colors.magenta]; class Emitter extends EventEmitter { /** diff --git a/package.json b/package.json index b595260c8b32..c22d749cb248 100644 --- a/package.json +++ b/package.json @@ -19,13 +19,14 @@ "build-extension": "yarn build-extension-chrome && yarn build-extension-firefox", "build-extension-chrome": "node ./build/build-extension.js chrome", "build-extension-firefox": "node ./build/build-extension.js firefox", - "build-devtools": "node ./build/build-bundle.js clients/devtools-entry.js dist/lighthouse-dt-bundle.js && node ./build/build-dt-report-resources.js", + "build-devtools": "yarn reset-link && node ./build/build-bundle.js clients/devtools-entry.js dist/lighthouse-dt-bundle.js && node ./build/build-dt-report-resources.js", "build-smokehouse-bundle": "node ./build/build-smokehouse-bundle.js", - "build-lr": "node ./build/build-lightrider-bundles.js", + "build-lr": "yarn reset-link && node ./build/build-lightrider-bundles.js", "build-pack": "bash build/build-pack.sh", "build-report": "node build/build-report.js", "build-treemap": "node ./build/build-treemap.js", "build-viewer": "node ./build/build-viewer.js", + "reset-link": "(yarn unlink || true) && yarn link && yarn link lighthouse", "c8": "bash lighthouse-core/scripts/c8.sh", "clean": "rm -r dist proto/scripts/*.json proto/scripts/*_pb2.* proto/scripts/*_pb.* proto/scripts/__pycache__ proto/scripts/*.pyc *.report.html *.report.dom.html *.report.json *.devtoolslog.json *.trace.json lighthouse-core/lib/i18n/locales/*.ctc.json || true", "lint": "[ \"$CI\" = true ] && eslint --quiet -f codeframe . || eslint .", From d7e7c1b7a505d71d600b2e33bb492cbb2c8b3bdd Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 9 Jul 2021 15:50:49 -0700 Subject: [PATCH 09/36] fix getBoundingClientRect mangle --- build/build-bundle.js | 1 + 1 file changed, 1 insertion(+) diff --git a/build/build-bundle.js b/build/build-bundle.js index bb0651ec2db2..df90e7809eb1 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -187,6 +187,7 @@ async function build(entryPath, distPath, opts = {minify: true}) { // the actual functions (getNodeDetails$1). The page functions expect a certain name, so // here we undo what Rollup did. postprocess([ + [/getBoundingClientRect\$1/, 'getBoundingClientRect'], [/getElementsInDocument\$1/, 'getElementsInDocument'], [/getNodeDetails\$1/, 'getNodeDetails'], [/getRectCenterPoint\$1/, 'getRectCenterPoint'], From 0fda79998c0abcc514c2bdeefe9ff1ac4d7a14af Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 9 Jul 2021 16:30:59 -0700 Subject: [PATCH 10/36] tweak --- build/build-bundle.js | 1 + 1 file changed, 1 insertion(+) diff --git a/build/build-bundle.js b/build/build-bundle.js index df90e7809eb1..2549c9cdb552 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -106,6 +106,7 @@ async function build(entryPath, distPath, opts = {minify: true}) { /** @type {Record} */ const shimsObj = {}; + const modulesToIgnore = [ 'intl-pluralrules', 'intl', From 213d949e424e620df1d186592abf64c69c001cba Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 9 Jul 2021 17:25:36 -0700 Subject: [PATCH 11/36] fix asset-saver --- build/rollup-brfs.js | 1 + build/rollup-postprocess.js | 10 +++++++--- lighthouse-core/fraggle-rock/gather/base-gatherer.js | 2 +- lighthouse-core/lib/asset-saver.js | 11 +++++++---- report/clients/standalone.js | 1 + 5 files changed, 17 insertions(+), 8 deletions(-) diff --git a/build/rollup-brfs.js b/build/rollup-brfs.js index 1b5b038790b8..fb6635094bf1 100644 --- a/build/rollup-brfs.js +++ b/build/rollup-brfs.js @@ -1,3 +1,4 @@ +// @ts-nocheck /** * @license Copyright 2021 The Lighthouse Authors. All Rights Reserved. * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 diff --git a/build/rollup-postprocess.js b/build/rollup-postprocess.js index 991e55525f44..01392ecb0991 100644 --- a/build/rollup-postprocess.js +++ b/build/rollup-postprocess.js @@ -1,3 +1,4 @@ +// @ts-nocheck /** * @license Copyright 2021 The Lighthouse Authors. All Rights Reserved. * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 @@ -15,9 +16,12 @@ module.exports = function postprocess(allReplacements) { name: 'postprocess', renderChunk(code, {sourceMap, format}) { const str = new MagicString(code); - const replacements = typeof allReplacements === 'function' ? allReplacements({code, sourceMap, format}) : allReplacements; + const replacements = typeof allReplacements === 'function' ? + allReplacements({code, sourceMap, format}) : + allReplacements; for (let i = 0; i < replacements.length; i++) { + // eslint-disable-next-line prefer-const let [find, replace = ''] = replacements[i]; if (typeof find === 'string') find = new RegExp(find); if (!find.global) { @@ -28,8 +32,8 @@ module.exports = function postprocess(allReplacements) { while (token = find.exec(code)) { let value; if (typeof replace === 'function') { - value = replace.apply(null, token); - if (value == null) value = ''; + value = replace(...token); + if (value === null) value = ''; } else { currentToken = token; value = replace.replace(/\$(\d+)/, replacer); diff --git a/lighthouse-core/fraggle-rock/gather/base-gatherer.js b/lighthouse-core/fraggle-rock/gather/base-gatherer.js index 1a89d41673ac..337a99a5a3ec 100644 --- a/lighthouse-core/fraggle-rock/gather/base-gatherer.js +++ b/lighthouse-core/fraggle-rock/gather/base-gatherer.js @@ -62,12 +62,12 @@ class FRGatherer { * @return {keyof LH.GathererArtifacts} */ get name() { - // @ts-expect-error - assume that class name has been added to LH.GathererArtifacts. let name = this.constructor.name; // Rollup will mangle class names in an known way–just trim until `$`. if (name.includes('$')) { name = name.substr(0, name.indexOf('$')); } + // @ts-expect-error - assume that class name has been added to LH.GathererArtifacts. return name; } diff --git a/lighthouse-core/lib/asset-saver.js b/lighthouse-core/lib/asset-saver.js index dba7885da653..23b98e32048e 100644 --- a/lighthouse-core/lib/asset-saver.js +++ b/lighthouse-core/lib/asset-saver.js @@ -9,12 +9,17 @@ const fs = require('fs'); const path = require('path'); const log = require('lighthouse-logger'); const stream = require('stream'); +const {promisify} = require('util'); const Simulator = require('./dependency-graph/simulator/simulator.js'); const lanternTraceSaver = require('./lantern-trace-saver.js'); const Metrics = require('./traces/pwmetrics-events.js'); const NetworkAnalysisComputed = require('../computed/network-analysis.js'); const LoadSimulatorComputed = require('../computed/load-simulator.js'); const LHError = require('../lib/lh-error.js'); +// TODO(esmodules): Rollup does not support `promisfy` or `stream.pipeline`. Bundled files +// don't need anything in this file except for `stringifyReplacer`, so a check for +// truthiness before using is enough. +const pipeline = promisify && promisify(stream.pipeline); const artifactsFilename = 'artifacts.json'; const traceSuffix = '.trace.json'; @@ -247,10 +252,8 @@ async function saveTrace(traceData, traceFilename) { function saveDevtoolsLog(devtoolsLog, devtoolLogFilename) { const logIter = arrayOfObjectsJsonGenerator(devtoolsLog); const writeStream = fs.createWriteStream(devtoolLogFilename); - return new Promise((resolve, reject) => { - stream.on('error', reject); - stream.on('done', resolve); - }); + + return pipeline(stream.Readable.from(logIter), writeStream); } /** diff --git a/report/clients/standalone.js b/report/clients/standalone.js index 35aa11551be9..4429e337cbe2 100644 --- a/report/clients/standalone.js +++ b/report/clients/standalone.js @@ -7,6 +7,7 @@ /* global document window ga DOM ReportRenderer ReportUIFeatures Logger */ +// eslint-disable-next-line no-unused-vars function __initLighthouseReport__() { const dom = new DOM(document); const renderer = new ReportRenderer(dom); From b975d117f0fc07f11bbf485d611842071d51762a Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 9 Jul 2021 18:19:30 -0700 Subject: [PATCH 12/36] fix lighthouse logger type check --- build/build-bundle.js | 7 +++++++ clients/devtools-entry.js | 2 +- lighthouse-core/lib/url-shim.js | 2 +- lighthouse-logger/index.js | 2 +- 4 files changed, 10 insertions(+), 3 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index 2549c9cdb552..8bbcfbb6e4b7 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -21,6 +21,7 @@ function rollupPluginTypeCoerce(module) { return module; } +const fs = require('fs'); const path = require('path'); const rollup = require('rollup'); const alias = rollupPluginTypeCoerce(require('@rollup/plugin-alias')); @@ -84,6 +85,10 @@ const banner = ` * @return {Promise} */ async function build(entryPath, distPath, opts = {minify: true}) { + if (fs.existsSync(LH_ROOT + '/lighthouse-logger/node_modules')) { + throw new Error('delete `lighthouse-logger/node_modules` because it messes up rollup bundle'); + } + // List of paths (absolute / relative to config-helpers.js) to include // in bundle and make accessible via config-helpers.js `requireWrapper`. const dynamicModulePaths = [ @@ -158,6 +163,7 @@ async function build(entryPath, distPath, opts = {minify: true}) { alias({ entries: { 'debug': require.resolve('debug/src/browser.js'), + 'lighthouse-logger': require.resolve('../lighthouse-logger/index.js'), 'url': require.resolve('../lighthouse-core/lib/url-shim.js'), }, }), @@ -192,6 +198,7 @@ async function build(entryPath, distPath, opts = {minify: true}) { [/getElementsInDocument\$1/, 'getElementsInDocument'], [/getNodeDetails\$1/, 'getNodeDetails'], [/getRectCenterPoint\$1/, 'getRectCenterPoint'], + [/isPositionFixed\$1/, 'isPositionFixed'], ]), opts.minify && terser({ ecma: 2019, diff --git a/clients/devtools-entry.js b/clients/devtools-entry.js index 191a34fc0449..686b1d0658b3 100644 --- a/clients/devtools-entry.js +++ b/clients/devtools-entry.js @@ -7,7 +7,7 @@ const lighthouse = require('../lighthouse-core/index.js'); const RawProtocol = require('../lighthouse-core/gather/connections/raw.js'); -const log = require('../lighthouse-logger/index.js'); +const log = require('lighthouse-logger'); const {registerLocaleData, lookupLocale} = require('../lighthouse-core/lib/i18n/i18n.js'); const constants = require('../lighthouse-core/config/constants.js'); diff --git a/lighthouse-core/lib/url-shim.js b/lighthouse-core/lib/url-shim.js index 441011b89b6d..bdd726018f2a 100644 --- a/lighthouse-core/lib/url-shim.js +++ b/lighthouse-core/lib/url-shim.js @@ -224,7 +224,7 @@ class URLShim extends URL { let url; try { url = new URL(src); - } catch (e) { + } catch { return undefined; } diff --git a/lighthouse-logger/index.js b/lighthouse-logger/index.js index a8b61cac191e..4076a0de4ebe 100644 --- a/lighthouse-logger/index.js +++ b/lighthouse-logger/index.js @@ -12,7 +12,7 @@ const marky = require('marky'); const EventEmitter = require('events').EventEmitter; const isWindows = process.platform === 'win32'; -// @ts-expect-error: process.browser is set when browserify'd via the `process` npm module +// @ts-expect-error: process.browser is set via Rollup. const isBrowser = process.browser; const colors = { From f90efbfdc90408cecb24bf7557a3745ebf7dfaf7 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 9 Jul 2021 18:43:37 -0700 Subject: [PATCH 13/36] dolla dolla bills --- .../lighthouse-successful-run-expected.txt | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/third-party/chromium-webtests/webtests/http/tests/devtools/lighthouse/lighthouse-successful-run-expected.txt b/third-party/chromium-webtests/webtests/http/tests/devtools/lighthouse/lighthouse-successful-run-expected.txt index c33594341107..f90f31792129 100644 --- a/third-party/chromium-webtests/webtests/http/tests/devtools/lighthouse/lighthouse-successful-run-expected.txt +++ b/third-party/chromium-webtests/webtests/http/tests/devtools/lighthouse/lighthouse-successful-run-expected.txt @@ -162,42 +162,42 @@ Auditing: Registers a service worker that controls page and `start_url` Auditing: Has a `` tag with `width` or `initial-scale` Computing artifact: ViewportMeta Auditing: First Contentful Paint -Computing artifact: FirstContentfulPaint +Computing artifact: FirstContentfulPaint$1 Computing artifact: LanternFirstContentfulPaint Computing artifact: PageDependencyGraph Computing artifact: LoadSimulator Computing artifact: NetworkAnalysis Auditing: Largest Contentful Paint -Computing artifact: LargestContentfulPaint +Computing artifact: LargestContentfulPaint$1 Computing artifact: LanternLargestContentfulPaint Auditing: First Meaningful Paint -Computing artifact: FirstMeaningfulPaint +Computing artifact: FirstMeaningfulPaint$1 Computing artifact: LanternFirstMeaningfulPaint Auditing: Speed Index -Computing artifact: SpeedIndex +Computing artifact: SpeedIndex$1 Computing artifact: LanternSpeedIndex Computing artifact: Speedline Auditing: Screenshot Thumbnails Auditing: Final Screenshot Computing artifact: Screenshots Auditing: Total Blocking Time -Computing artifact: TotalBlockingTime +Computing artifact: TotalBlockingTime$1 Computing artifact: LanternTotalBlockingTime Computing artifact: LanternInteractive Auditing: Max Potential First Input Delay -Computing artifact: MaxPotentialFID +Computing artifact: MaxPotentialFID$1 Computing artifact: LanternMaxPotentialFID Auditing: Cumulative Layout Shift -Computing artifact: CumulativeLayoutShift +Computing artifact: CumulativeLayoutShift$1 Auditing: No browser errors logged to the console Auditing: Initial server response time was short Computing artifact: MainResource Auditing: Time to Interactive Computing artifact: Interactive Auditing: User Timing marks and measures -Computing artifact: UserTimings +Computing artifact: UserTimings$1 Auditing: Avoid chaining critical requests -Computing artifact: CriticalRequestChains +Computing artifact: CriticalRequestChains$1 Auditing: Avoid multiple page redirects Auditing: Web app manifest and service worker meet the installability requirements Computing artifact: ManifestValues @@ -213,7 +213,7 @@ Auditing: Serves images with appropriate resolution Auditing: Fonts with `font-display: optional` are preloaded Auditing: Avoids deprecated APIs Auditing: Minimizes main-thread work -Computing artifact: MainThreadTasks +Computing artifact: MainThreadTasks$1 Auditing: JavaScript execution time Auditing: Preload key requests Auditing: Preconnect to required origins @@ -226,7 +226,7 @@ Auditing: Tasks Auditing: Metrics Computing artifact: TimingSummary Auditing: Performance budget -Computing artifact: ResourceSummary +Computing artifact: ResourceSummary$1 Auditing: Timing budget Auditing: Keep request counts low and transfer sizes small Auditing: Minimize third-party usage @@ -306,7 +306,7 @@ Auditing: Avoids enormous network payloads Auditing: Defer offscreen images Auditing: Eliminate render-blocking resources Computing artifact: UnusedCSS -Computing artifact: FirstContentfulPaint +Computing artifact: FirstContentfulPaint$1 Auditing: Minify CSS Auditing: Minify JavaScript Auditing: Reduce unused CSS @@ -374,7 +374,7 @@ Auditing: Ad tag is loaded over HTTPS Auditing: Ad scripts are loaded statically Auditing: Header bidding is parallelized Auditing: Tag load time -Computing artifact: TagLoadTime +Computing artifact: TagLoadTime$1 Computing artifact: LanternTagLoadTime Auditing: Ad density is within recommended range Auditing: Cumulative ad shift From 4c96a26fa2c0934f435956e74b3e0485a43ac454 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 23 Jul 2021 13:04:02 -0700 Subject: [PATCH 14/36] postprocess package --- build/build-bundle.js | 2 +- build/rollup-postprocess.js | 51 ---------------------------- package.json | 1 + types/rollup-plugin-postprocess.d.ts | 10 ++++++ yarn.lock | 7 ++++ 5 files changed, 19 insertions(+), 52 deletions(-) delete mode 100644 build/rollup-postprocess.js create mode 100644 types/rollup-plugin-postprocess.d.ts diff --git a/build/build-bundle.js b/build/build-bundle.js index 8bbcfbb6e4b7..296f4a8efcf2 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -30,10 +30,10 @@ const json = rollupPluginTypeCoerce(require('@rollup/plugin-json')); const nodePolyfills = rollupPluginTypeCoerce(require('rollup-plugin-node-polyfills')); const nodeResolve = rollupPluginTypeCoerce(require('rollup-plugin-node-resolve')); const replace = rollupPluginTypeCoerce(require('rollup-plugin-replace')); +const postprocess = require('@stadtlandnetz/rollup-plugin-postprocess'); // @ts-expect-error: no types const shim = require('rollup-plugin-shim'); const {terser} = require('rollup-plugin-terser'); -const postprocess = require('./rollup-postprocess.js'); const {minifyFileTransform} = require('./build-utils.js'); const Runner = require('../lighthouse-core/runner.js'); const rollupBrfs = require('./rollup-brfs.js'); diff --git a/build/rollup-postprocess.js b/build/rollup-postprocess.js deleted file mode 100644 index 01392ecb0991..000000000000 --- a/build/rollup-postprocess.js +++ /dev/null @@ -1,51 +0,0 @@ -// @ts-nocheck -/** - * @license Copyright 2021 The Lighthouse Authors. All Rights Reserved. - * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 - * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. - */ -'use strict'; - -const MagicString = require('magic-string'); - -let currentToken; -const replacer = (str, index) => currentToken[index]; - -module.exports = function postprocess(allReplacements) { - return { - name: 'postprocess', - renderChunk(code, {sourceMap, format}) { - const str = new MagicString(code); - const replacements = typeof allReplacements === 'function' ? - allReplacements({code, sourceMap, format}) : - allReplacements; - - for (let i = 0; i < replacements.length; i++) { - // eslint-disable-next-line prefer-const - let [find, replace = ''] = replacements[i]; - if (typeof find === 'string') find = new RegExp(find); - if (!find.global) { - find = new RegExp(find.source, 'g' + String(find).split('/').pop()); - } - - let token; - while (token = find.exec(code)) { - let value; - if (typeof replace === 'function') { - value = replace(...token); - if (value === null) value = ''; - } else { - currentToken = token; - value = replace.replace(/\$(\d+)/, replacer); - } - str.overwrite(token.index, token.index + token[0].length, value); - } - } - - return { - code: str.toString(), - map: sourceMap === false ? null : str.generateMap({hires: true}), - }; - }, - }; -}; diff --git a/package.json b/package.json index 7a030c711131..a28f64619d73 100644 --- a/package.json +++ b/package.json @@ -96,6 +96,7 @@ "@rollup/plugin-alias": "^3.1.2", "@rollup/plugin-dynamic-import-vars": "^1.1.1", "@rollup/plugin-json": "^4.1.0", + "@stadtlandnetz/rollup-plugin-postprocess": "^1.1.0", "@types/archiver": "^2.1.2", "@types/browserify": "^12.0.36", "@types/chrome": "^0.0.60", diff --git a/types/rollup-plugin-postprocess.d.ts b/types/rollup-plugin-postprocess.d.ts new file mode 100644 index 000000000000..b68c5fdcb252 --- /dev/null +++ b/types/rollup-plugin-postprocess.d.ts @@ -0,0 +1,10 @@ +/** + * @license Copyright 2021 The Lighthouse Authors. All Rights Reserved. + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. + */ + +declare module '@stadtlandnetz/rollup-plugin-postprocess' { + function postprocess(args: Array<[RegExp, string]>): void; + export = postprocess; +} diff --git a/yarn.lock b/yarn.lock index a71f0ac78ca6..9b4bd59b12c0 100644 --- a/yarn.lock +++ b/yarn.lock @@ -815,6 +815,13 @@ dependencies: "@sinonjs/commons" "^1.7.0" +"@stadtlandnetz/rollup-plugin-postprocess@^1.1.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@stadtlandnetz/rollup-plugin-postprocess/-/rollup-plugin-postprocess-1.1.0.tgz#b754df3b315f1ba1af0ae2ca4ccad047f71086b0" + integrity sha512-mj3Da2lsAX4+7V8AEQLrVDf1c9wTT9QFm8AZaYdnaU82cLEN9Xix9m27w6m5leVxXFpMWnOnRVq14HF/8/1/eQ== + dependencies: + magic-string "^0.25.7" + "@szmarczak/http-timer@^1.1.2": version "1.1.2" resolved "https://registry.yarnpkg.com/@szmarczak/http-timer/-/http-timer-1.1.2.tgz#b1665e2c461a2cd92f4c1bbf50d5454de0d4b421" From 03ca85022536a77d6170649f79c20e97101e5b23 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 13 Aug 2021 12:20:34 -0700 Subject: [PATCH 15/36] readfile --- build/build-bundle.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index 296f4a8efcf2..d3d752567ea2 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -57,7 +57,6 @@ const isLightrider = file => path.basename(file).includes('lightrider'); // Set to true for source maps. const DEBUG = false; -const pkg = require('../package.json'); const today = (() => { const date = new Date(); const year = new Intl.DateTimeFormat('en', {year: 'numeric'}).format(date); @@ -65,6 +64,7 @@ const today = (() => { const day = new Intl.DateTimeFormat('en', {day: '2-digit'}).format(date); return `${month} ${day} ${year}`; })(); +const pkg = JSON.parse(fs.readFileSync(LH_ROOT + '/package.json', 'utf-8')); const banner = ` /** * Lighthouse v${pkg.version} ${COMMIT_HASH} (${today}) From a1a0ff6267a9180024d31a82de1ac24730e2bc06 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Wed, 15 Sep 2021 13:34:24 -0700 Subject: [PATCH 16/36] wip --- build/build-bundle.js | 2 + .../metrics/lantern-total-blocking-time.js | 7 +-- lighthouse-core/computed/metrics/tbt-utils.js | 57 +++++++++++++++++++ .../computed/metrics/total-blocking-time.js | 56 +----------------- lighthouse-core/index.js | 7 +++ yarn.lock | 6 +- 6 files changed, 75 insertions(+), 60 deletions(-) create mode 100644 lighthouse-core/computed/metrics/tbt-utils.js diff --git a/build/build-bundle.js b/build/build-bundle.js index e4c8f6fa831c..a5dedfe2d488 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -188,6 +188,8 @@ async function build(entryPath, distPath, opts = {minify: true}) { }), json(), nodeResolve({preferBuiltins: true}), + // TODO: ideally would use https://github.com/snowpackjs/rollup-plugin-polyfill-node + // More maintained. also has EventEmitter.off. But it gets rollup errors from commonjs. nodePolyfills(), // Rollup sees the usages of these functions in page functions (ex: see AnchorElements) // and treats them as globals. Because the names are "taken" by the global, Rollup renames diff --git a/lighthouse-core/computed/metrics/lantern-total-blocking-time.js b/lighthouse-core/computed/metrics/lantern-total-blocking-time.js index 082625327cbf..0bff853cf216 100644 --- a/lighthouse-core/computed/metrics/lantern-total-blocking-time.js +++ b/lighthouse-core/computed/metrics/lantern-total-blocking-time.js @@ -10,6 +10,7 @@ const LanternMetric = require('./lantern-metric.js'); const BaseNode = require('../../lib/dependency-graph/base-node.js'); const LanternFirstContentfulPaint = require('./lantern-first-contentful-paint.js'); const LanternInteractive = require('./lantern-interactive.js'); +const {BLOCKING_TIME_THRESHOLD, calculateSumOfBlockingTime} = require('./tbt-utils.js'); /** @typedef {BaseNode.Node} Node */ @@ -66,9 +67,7 @@ class LanternTotalBlockingTime extends LanternMetric { ? extras.interactiveResult.optimisticEstimate.timeInMs : extras.interactiveResult.pessimisticEstimate.timeInMs; - // Require here to resolve circular dependency. - const TotalBlockingTime = require('./total-blocking-time.js'); - const minDurationMs = TotalBlockingTime.BLOCKING_TIME_THRESHOLD; + const minDurationMs = BLOCKING_TIME_THRESHOLD; const events = LanternTotalBlockingTime.getTopLevelEvents( simulation.nodeTimings, @@ -76,7 +75,7 @@ class LanternTotalBlockingTime extends LanternMetric { ); return { - timeInMs: TotalBlockingTime.calculateSumOfBlockingTime( + timeInMs: calculateSumOfBlockingTime( events, fcpTimeInMs, interactiveTimeMs diff --git a/lighthouse-core/computed/metrics/tbt-utils.js b/lighthouse-core/computed/metrics/tbt-utils.js new file mode 100644 index 000000000000..657d9a976216 --- /dev/null +++ b/lighthouse-core/computed/metrics/tbt-utils.js @@ -0,0 +1,57 @@ +/** + * @license Copyright 2021 The Lighthouse Authors. All Rights Reserved. + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. + */ +'use strict'; + +const BLOCKING_TIME_THRESHOLD = 50; + +/** + * @param {Array<{start: number, end: number, duration: number}>} topLevelEvents + * @param {number} startTimeMs + * @param {number} endTimeMs + * @return {number} + */ +function calculateSumOfBlockingTime(topLevelEvents, startTimeMs, endTimeMs) { + if (endTimeMs <= startTimeMs) return 0; + + const threshold = BLOCKING_TIME_THRESHOLD; + let sumBlockingTime = 0; + for (const event of topLevelEvents) { + // Early exit for small tasks, which should far outnumber long tasks. + if (event.duration < threshold) continue; + + // We only want to consider tasks that fall in our time range (FCP and TTI for navigations). + // FCP is picked as the lower bound because there is little risk of user input happening + // before FCP so Long Queuing Qelay regions do not harm user experience. Developers should be + // optimizing to reach FCP as fast as possible without having to worry about task lengths. + if (event.end < startTimeMs) continue; + + // TTI is picked as the upper bound because we want a well defined end point for page load. + if (event.start > endTimeMs) continue; + + // We first perform the clipping, and then calculate Blocking Region. So if we have a 150ms + // task [0, 150] and FCP happens midway at 50ms, we first clip the task to [50, 150], and then + // calculate the Blocking Region to be [100, 150]. The rational here is that tasks before FCP + // are unimportant, so we care whether the main thread is busy more than 50ms at a time only + // after FCP. + const clippedStart = Math.max(event.start, startTimeMs); + const clippedEnd = Math.min(event.end, endTimeMs); + const clippedDuration = clippedEnd - clippedStart; + if (clippedDuration < threshold) continue; + + // The duration of the task beyond 50ms at the beginning is considered the Blocking Region. + // Example: + // [ 250ms Task ] + // | First 50ms | Blocking Region (200ms) | + sumBlockingTime += clippedDuration - threshold; + } + + return sumBlockingTime; +} + +module.exports = { + BLOCKING_TIME_THRESHOLD, + calculateSumOfBlockingTime, +}; diff --git a/lighthouse-core/computed/metrics/total-blocking-time.js b/lighthouse-core/computed/metrics/total-blocking-time.js index c9d26cd5bd00..017444ef706a 100644 --- a/lighthouse-core/computed/metrics/total-blocking-time.js +++ b/lighthouse-core/computed/metrics/total-blocking-time.js @@ -10,6 +10,7 @@ const ComputedMetric = require('./metric.js'); const TraceProcessor = require('../../lib/tracehouse/trace-processor.js'); const LanternTotalBlockingTime = require('./lantern-total-blocking-time.js'); const TimetoInteractive = require('./interactive.js'); +const {calculateSumOfBlockingTime} = require('./tbt-utils.js'); /** * @fileoverview This audit determines Total Blocking Time. @@ -25,57 +26,6 @@ const TimetoInteractive = require('./interactive.js'); * to smaller improvements to main thread responsiveness. */ class TotalBlockingTime extends ComputedMetric { - /** - * @return {number} - */ - static get BLOCKING_TIME_THRESHOLD() { - return 50; - } - - /** - * @param {Array<{start: number, end: number, duration: number}>} topLevelEvents - * @param {number} startTimeMs - * @param {number} endTimeMs - * @return {number} - */ - static calculateSumOfBlockingTime(topLevelEvents, startTimeMs, endTimeMs) { - if (endTimeMs <= startTimeMs) return 0; - - const threshold = TotalBlockingTime.BLOCKING_TIME_THRESHOLD; - let sumBlockingTime = 0; - for (const event of topLevelEvents) { - // Early exit for small tasks, which should far outnumber long tasks. - if (event.duration < threshold) continue; - - // We only want to consider tasks that fall in our time range (FCP and TTI for navigations). - // FCP is picked as the lower bound because there is little risk of user input happening - // before FCP so Long Queuing Qelay regions do not harm user experience. Developers should be - // optimizing to reach FCP as fast as possible without having to worry about task lengths. - if (event.end < startTimeMs) continue; - - // TTI is picked as the upper bound because we want a well defined end point for page load. - if (event.start > endTimeMs) continue; - - // We first perform the clipping, and then calculate Blocking Region. So if we have a 150ms - // task [0, 150] and FCP happens midway at 50ms, we first clip the task to [50, 150], and then - // calculate the Blocking Region to be [100, 150]. The rational here is that tasks before FCP - // are unimportant, so we care whether the main thread is busy more than 50ms at a time only - // after FCP. - const clippedStart = Math.max(event.start, startTimeMs); - const clippedEnd = Math.min(event.end, endTimeMs); - const clippedDuration = clippedEnd - clippedStart; - if (clippedDuration < threshold) continue; - - // The duration of the task beyond 50ms at the beginning is considered the Blocking Region. - // Example: - // [ 250ms Task ] - // | First 50ms | Blocking Region (200ms) | - sumBlockingTime += clippedDuration - threshold; - } - - return sumBlockingTime; - } - /** * @param {LH.Artifacts.MetricComputationData} data * @param {LH.Artifacts.ComputedContext} context @@ -100,7 +50,7 @@ class TotalBlockingTime extends ComputedMetric { const interactiveTimeMs = (await TimetoInteractive.request(metricData, context)).timing; return { - timing: TotalBlockingTime.calculateSumOfBlockingTime( + timing: calculateSumOfBlockingTime( events, firstContentfulPaint, interactiveTimeMs @@ -108,7 +58,7 @@ class TotalBlockingTime extends ComputedMetric { }; } else { return { - timing: TotalBlockingTime.calculateSumOfBlockingTime( + timing: calculateSumOfBlockingTime( events, 0, data.processedTrace.timestamps.traceEnd diff --git a/lighthouse-core/index.js b/lighthouse-core/index.js index 4c0acf298610..fc3f2b536da0 100644 --- a/lighthouse-core/index.js +++ b/lighthouse-core/index.js @@ -5,6 +5,7 @@ */ 'use strict'; +const EventEmitter = require('events'); const Runner = require('./runner.js'); const log = require('lighthouse-logger'); const ChromeProtocol = require('./gather/connections/cri.js'); @@ -12,6 +13,12 @@ const Config = require('./config/config.js'); /** @typedef {import('./gather/connections/connection.js')} Connection */ +// rollup-plugin-node-polyfills does not polyfill EventEmitter.off, +// so do it manually. +if (!EventEmitter.prototype.off) { + EventEmitter.prototype.off = EventEmitter.prototype.removeListener; +} + /* * The relationship between these root modules: * diff --git a/yarn.lock b/yarn.lock index 14f8133bd34b..31a39d07eada 100644 --- a/yarn.lock +++ b/yarn.lock @@ -7492,9 +7492,9 @@ rollup-pluginutils@^2.6.0, rollup-pluginutils@^2.8.1: estree-walker "^0.6.1" rollup@^2.52.7: - version "2.52.7" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.52.7.tgz#e15a8bf734f6e4c204b7cdf33521151310250cb2" - integrity sha512-55cSH4CCU6MaPr9TAOyrIC+7qFCHscL7tkNsm1MBfIJRRqRbCEY0mmeFn4Wg8FKsHtEH8r389Fz38r/o+kgXLg== + version "2.56.3" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.56.3.tgz#b63edadd9851b0d618a6d0e6af8201955a77aeff" + integrity sha512-Au92NuznFklgQCUcV96iXlxUbHuB1vQMaH76DHl5M11TotjOHwqk9CwcrT78+Tnv4FN9uTBxq6p4EJoYkpyekg== optionalDependencies: fsevents "~2.3.2" From 3cf53034aeb1687628a3af5d0e7bfaadf673d6f7 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Wed, 15 Sep 2021 14:39:41 -0700 Subject: [PATCH 17/36] fix --- .../metrics/total-blocking-time-test.js | 21 ++++++++++--------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/lighthouse-core/test/computed/metrics/total-blocking-time-test.js b/lighthouse-core/test/computed/metrics/total-blocking-time-test.js index 92ae6d18c6c0..e76fda39d017 100644 --- a/lighthouse-core/test/computed/metrics/total-blocking-time-test.js +++ b/lighthouse-core/test/computed/metrics/total-blocking-time-test.js @@ -8,6 +8,7 @@ const TotalBlockingTime = require('../../../computed/metrics/total-blocking-time.js'); const trace = require('../../fixtures/traces/progressive-app-m60.json'); const devtoolsLog = require('../../fixtures/traces/progressive-app-m60.devtools.log.json'); +const {calculateSumOfBlockingTime} = require('../../../computed/metrics/tbt-utils.js'); /* eslint-env jest */ @@ -52,7 +53,7 @@ describe('Metrics: TotalBlockingTime', () => { const interactiveTimeMs = 4000; expect( - TotalBlockingTime.calculateSumOfBlockingTime(events, fcpTimeMs, interactiveTimeMs) + calculateSumOfBlockingTime(events, fcpTimeMs, interactiveTimeMs) ).toBe(0); }); @@ -68,7 +69,7 @@ describe('Metrics: TotalBlockingTime', () => { const interactiveTimeMs = 2500; expect( - TotalBlockingTime.calculateSumOfBlockingTime(events, fcpTimeMs, interactiveTimeMs) + calculateSumOfBlockingTime(events, fcpTimeMs, interactiveTimeMs) ).toBe(150); }); @@ -87,7 +88,7 @@ describe('Metrics: TotalBlockingTime', () => { ]; expect( - TotalBlockingTime.calculateSumOfBlockingTime(events, fcpTimeMs, interactiveTimeMs) + calculateSumOfBlockingTime(events, fcpTimeMs, interactiveTimeMs) ).toBe(10); // 0ms + 10ms. }); @@ -99,21 +100,21 @@ describe('Metrics: TotalBlockingTime', () => { const interactiveTimeMs = 2000; expect( - TotalBlockingTime.calculateSumOfBlockingTime( + calculateSumOfBlockingTime( [{start: 1951, end: 2100, duration: 149}], fcpTimeMs, interactiveTimeMs ) ).toBe(0); // Duration after clipping is 49, which is < 50. expect( - TotalBlockingTime.calculateSumOfBlockingTime( + calculateSumOfBlockingTime( [{start: 1950, end: 2100, duration: 150}], fcpTimeMs, interactiveTimeMs ) ).toBe(0); // Duration after clipping is 50, so time after 50ms is 0ms. expect( - TotalBlockingTime.calculateSumOfBlockingTime( + calculateSumOfBlockingTime( [{start: 1949, end: 2100, duration: 151}], fcpTimeMs, interactiveTimeMs @@ -126,21 +127,21 @@ describe('Metrics: TotalBlockingTime', () => { const interactiveTimeMs = 2000; expect( - TotalBlockingTime.calculateSumOfBlockingTime( + calculateSumOfBlockingTime( [{start: 900, end: 1049, duration: 149}], fcpTimeMs, interactiveTimeMs ) ).toBe(0); // Duration after clipping is 49, which is < 50. expect( - TotalBlockingTime.calculateSumOfBlockingTime( + calculateSumOfBlockingTime( [{start: 900, end: 1050, duration: 150}], fcpTimeMs, interactiveTimeMs ) ).toBe(0); // Duration after clipping is 50, so time after 50ms is 0ms. expect( - TotalBlockingTime.calculateSumOfBlockingTime( + calculateSumOfBlockingTime( [{start: 900, end: 1051, duration: 151}], fcpTimeMs, interactiveTimeMs @@ -157,7 +158,7 @@ describe('Metrics: TotalBlockingTime', () => { const events = [{start: 500, end: 3000, duration: 2500}]; expect( - TotalBlockingTime.calculateSumOfBlockingTime(events, fcpTimeMs, interactiveTimeMs) + calculateSumOfBlockingTime(events, fcpTimeMs, interactiveTimeMs) ).toBe(0); }); }); From 667b536d8d64520e6899b7b487aceecc77c58dd4 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 24 Sep 2021 16:25:03 -0700 Subject: [PATCH 18/36] build: create rollup-plugins.js helper module --- build/build-report.js | 31 ++++++------------- build/build-smokehouse-bundle.js | 23 +++----------- build/gh-pages-app.js | 12 +++----- build/rollup-plugins.js | 32 ++++++++++++++++++++ package.json | 2 +- yarn.lock | 52 +++++++++++++++++++++++--------- 6 files changed, 89 insertions(+), 63 deletions(-) create mode 100644 build/rollup-plugins.js diff --git a/build/build-report.js b/build/build-report.js index cc051da684ac..4195f4d0eb47 100644 --- a/build/build-report.js +++ b/build/build-report.js @@ -6,25 +6,14 @@ 'use strict'; const rollup = require('rollup'); -const {nodeResolve} = require('@rollup/plugin-node-resolve'); -const {terser} = require('rollup-plugin-terser'); -// Only needed b/c getFilenamePrefix loads a commonjs module. -const commonjs = - // @ts-expect-error types are wrong. - /** @type {import('rollup-plugin-commonjs').default} */ (require('rollup-plugin-commonjs')); - -/** - * @type {import('@rollup/plugin-typescript').default} - */ -// @ts-expect-error types are wrong. -const typescript = require('@rollup/plugin-typescript'); +const rollupPlugins = require('./rollup-plugins.js'); async function buildStandaloneReport() { const bundle = await rollup.rollup({ input: 'report/clients/standalone.js', plugins: [ - commonjs(), - terser(), + rollupPlugins.commonjs(), + rollupPlugins.terser(), ], }); @@ -38,9 +27,9 @@ async function buildFlowReport() { const bundle = await rollup.rollup({ input: 'flow-report/standalone-flow.tsx', plugins: [ - nodeResolve(), - commonjs(), - typescript({ + rollupPlugins.nodeResolve(), + rollupPlugins.commonjs(), + rollupPlugins.typescript({ tsconfig: 'flow-report/tsconfig.json', // Plugin struggles with custom outDir, so revert it from tsconfig value // as well as any options that require an outDir is set. @@ -49,7 +38,7 @@ async function buildFlowReport() { emitDeclarationOnly: false, declarationMap: false, }), - terser(), + rollupPlugins.terser(), ], }); @@ -63,7 +52,7 @@ async function buildPsiReport() { const bundle = await rollup.rollup({ input: 'report/clients/psi.js', plugins: [ - commonjs(), + rollupPlugins.commonjs(), ], }); @@ -77,7 +66,7 @@ async function buildEsModulesBundle() { const bundle = await rollup.rollup({ input: 'report/clients/bundle.js', plugins: [ - commonjs(), + rollupPlugins.commonjs(), ], }); @@ -91,7 +80,7 @@ async function buildUmdBundle() { const bundle = await rollup.rollup({ input: 'report/clients/bundle.js', plugins: [ - commonjs(), + rollupPlugins.commonjs(), ], }); diff --git a/build/build-smokehouse-bundle.js b/build/build-smokehouse-bundle.js index 0b9ad9ebdc25..db46639fcaf1 100644 --- a/build/build-smokehouse-bundle.js +++ b/build/build-smokehouse-bundle.js @@ -6,22 +6,7 @@ 'use strict'; const rollup = require('rollup'); - -/** - * Rollup plugins don't export types that work with commonjs. - * @template T - * @param {T} module - * @return {T['default']} - */ -function rollupPluginTypeCoerce(module) { - // @ts-expect-error - return module; -} - -const nodeResolve = rollupPluginTypeCoerce(require('rollup-plugin-node-resolve')); -const commonjs = rollupPluginTypeCoerce(require('rollup-plugin-commonjs')); -// @ts-expect-error: no types -const shim = require('rollup-plugin-shim'); +const rollupPlugins = require('./rollup-plugins.js'); const {LH_ROOT} = require('../root.js'); const distDir = `${LH_ROOT}/dist`; @@ -35,9 +20,9 @@ async function build() { input: smokehouseLibFilename, context: 'globalThis', plugins: [ - nodeResolve(), - commonjs(), - shim({ + rollupPlugins.nodeResolve(), + rollupPlugins.commonjs(), + rollupPlugins.shim({ [smokehouseCliFilename]: 'export default {}', }), ], diff --git a/build/gh-pages-app.js b/build/gh-pages-app.js index 0b21cbcc71ba..fd4029388b9f 100644 --- a/build/gh-pages-app.js +++ b/build/gh-pages-app.js @@ -8,11 +8,7 @@ const fs = require('fs'); const path = require('path'); const rollup = require('rollup'); -const commonjs = - // @ts-expect-error types are wrong. - /** @type {import('rollup-plugin-commonjs').default} */ (require('rollup-plugin-commonjs')); -const {terser: rollupTerser} = require('rollup-plugin-terser'); -const {nodeResolve} = require('@rollup/plugin-node-resolve'); +const rollupPlugins = require('./rollup-plugins.js'); const cpy = require('cpy'); const ghPages = require('gh-pages'); const glob = require('glob'); @@ -146,10 +142,10 @@ class GhPagesApp { */ async _rollupSource(input) { const plugins = [ - nodeResolve(), - commonjs(), + rollupPlugins.nodeResolve(), + rollupPlugins.commonjs(), ]; - if (!process.env.DEBUG) plugins.push(rollupTerser()); + if (!process.env.DEBUG) plugins.push(rollupPlugins.terser()); const bundle = await rollup.rollup({ input, plugins, diff --git a/build/rollup-plugins.js b/build/rollup-plugins.js new file mode 100644 index 000000000000..3328f1047416 --- /dev/null +++ b/build/rollup-plugins.js @@ -0,0 +1,32 @@ +/** + * @license Copyright 2021 The Lighthouse Authors. All Rights Reserved. + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. + */ +'use strict'; + +/** + * Rollup plugins don't export types that work with commonjs. + * @template T + * @param {T} module + * @return {T['default']} + */ +function rollupPluginTypeCoerce(module) { + // @ts-expect-error + return module; +} + +const commonjs = rollupPluginTypeCoerce(require('@rollup/plugin-commonjs')); +const {nodeResolve} = require('@rollup/plugin-node-resolve'); +// @ts-expect-error: no published types. +const shim = require('rollup-plugin-shim'); +const {terser} = require('rollup-plugin-terser'); +const typescript = rollupPluginTypeCoerce(require('@rollup/plugin-typescript')); + +module.exports = { + commonjs, + nodeResolve, + shim, + terser, + typescript, +}; diff --git a/package.json b/package.json index a10fd81621a4..2b6985c32a70 100644 --- a/package.json +++ b/package.json @@ -92,6 +92,7 @@ }, "devDependencies": { "@build-tracker/cli": "^1.0.0-beta.15", + "@rollup/plugin-commonjs": "^20.0.0", "@rollup/plugin-node-resolve": "^13.0.4", "@rollup/plugin-typescript": "^8.2.5", "@testing-library/preact": "^2.0.1", @@ -163,7 +164,6 @@ "pretty-json-stringify": "^0.0.2", "puppeteer": "^10.2.0", "rollup": "^2.50.6", - "rollup-plugin-commonjs": "^10.1.0", "rollup-plugin-node-resolve": "^5.2.0", "rollup-plugin-shim": "^1.0.0", "rollup-plugin-terser": "^7.0.2", diff --git a/yarn.lock b/yarn.lock index cf353e7d47e3..619f476c3608 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1212,6 +1212,19 @@ resolved "https://registry.yarnpkg.com/@protobufjs/utf8/-/utf8-1.1.0.tgz#a777360b5b39a1a2e5106f8e858f2fd2d060c570" integrity sha1-p3c2C1s5oaLlEG+OhY8v0tBgxXA= +"@rollup/plugin-commonjs@^20.0.0": + version "20.0.0" + resolved "https://registry.yarnpkg.com/@rollup/plugin-commonjs/-/plugin-commonjs-20.0.0.tgz#3246872dcbcb18a54aaa6277a8c7d7f1b155b745" + integrity sha512-5K0g5W2Ol8hAcTHqcTBHiA7M58tfmYi1o9KxeJuuRNpGaTa5iLjcyemBitCBcKXaHamOBBEH2dGom6v6Unmqjg== + dependencies: + "@rollup/pluginutils" "^3.1.0" + commondir "^1.0.1" + estree-walker "^2.0.1" + glob "^7.1.6" + is-reference "^1.2.1" + magic-string "^0.25.7" + resolve "^1.17.0" + "@rollup/plugin-node-resolve@^13.0.4": version "13.0.4" resolved "https://registry.yarnpkg.com/@rollup/plugin-node-resolve/-/plugin-node-resolve-13.0.4.tgz#b10222f4145a019740acb7738402130d848660c0" @@ -2944,6 +2957,11 @@ commander@~2.17.1: resolved "https://registry.yarnpkg.com/commander/-/commander-2.17.1.tgz#bd77ab7de6de94205ceacc72f1716d29f20a77bf" integrity sha512-wPMUt6FnH2yzG95SA6mzjQOEKUU3aLaDEmzs1ti+1E9h+CsrZghRlqEM/EJ4KscsQVG8uNN4uVreUeT8+drlgg== +commondir@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b" + integrity sha1-3dgA2gxmEnOTzKWVDqloo6rxJTs= + compare-func@^1.3.1: version "1.3.2" resolved "https://registry.yarnpkg.com/compare-func/-/compare-func-1.3.2.tgz#99dd0ba457e1f9bc722b12c08ec33eeab31fa648" @@ -4082,6 +4100,11 @@ estree-walker@^1.0.1: resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-1.0.1.tgz#31bc5d612c96b704106b477e6dd5d8aa138cb700" integrity sha512-1fMXF3YP4pZZVozF8j/ZLfvnR8NSIljt56UhbZ5PeeDmmGHpgpdwQt7ITlGvYaQukCvuBRMLEiKiYC+oeIg4cg== +estree-walker@^2.0.1: + version "2.0.2" + resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-2.0.2.tgz#52f010178c2a4c117a7757cfe942adb7d2da4cac" + integrity sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w== + esutils@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz#0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b" @@ -4685,6 +4708,18 @@ glob@^7.0.0, glob@^7.0.3, glob@^7.1.0, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3, gl once "^1.3.0" path-is-absolute "^1.0.0" +glob@^7.1.6: + version "7.2.0" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.0.tgz#d15535af7732e02e948f4c41628bd910293f6023" + integrity sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q== + dependencies: + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" + global-dirs@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/global-dirs/-/global-dirs-2.0.1.tgz#acdf3bb6685bcd55cb35e8a052266569e9469201" @@ -5410,7 +5445,7 @@ is-potential-custom-element-name@^1.0.1: resolved "https://registry.yarnpkg.com/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz#171ed6f19e3ac554394edf78caa05784a45bebb5" integrity sha512-bCYeRA2rVibKZd+s2625gGnGF/t7DSqDs4dP7CrLA1m7jKWz6pps0LpYLJN8Q64HtmPKJ1hrN3nzPNKFEKOUiQ== -is-reference@^1.1.2: +is-reference@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/is-reference/-/is-reference-1.2.1.tgz#8b2dac0b371f4bc994fdeaba9eb542d03002d0b7" integrity sha512-U82MsXXiFIrjCK4otLT+o2NA2Cd2g5MLoOVXUZjIOhLurrRxpEXzI8O0KZHr3IjLvlAH1kTPYSuqer5T9ZVBKQ== @@ -6559,7 +6594,7 @@ magic-string@0.25.1: dependencies: sourcemap-codec "^1.4.1" -magic-string@^0.25.2: +magic-string@^0.25.7: version "0.25.7" resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.25.7.tgz#3f497d6fd34c669c6798dcb821f2ef31f5445051" integrity sha512-4CrMT5DOHTDk4HYDlzmwu4FVCcIYI8gauveasrdCu2IKIFOJ3f0v/8MDGJCDL9oD2ppz/Av1b0Nj345H9M+XIA== @@ -7938,7 +7973,7 @@ resolve-url@^0.2.1: resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" integrity sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo= -resolve@^1.1.4, resolve@^1.1.5, resolve@^1.10.0, resolve@^1.11.0, resolve@^1.11.1, resolve@^1.17.0, resolve@^1.19.0, resolve@^1.20.0, resolve@^1.4.0: +resolve@^1.1.4, resolve@^1.1.5, resolve@^1.10.0, resolve@^1.11.1, resolve@^1.17.0, resolve@^1.19.0, resolve@^1.20.0, resolve@^1.4.0: version "1.20.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.20.0.tgz#629a013fb3f70755d6f0b7935cc1c2c5378b1975" integrity sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A== @@ -7997,17 +8032,6 @@ robots-parser@^2.0.1: resolved "https://registry.npmjs.org/robots-parser/-/robots-parser-2.1.0.tgz#d16b78ce34e861ab6afbbf0aac65974dbe01566e" integrity sha512-k07MeDS1Tl1zjoYs5bHfUbgQ0MfaeTOepDcjZFxdYXd84p6IeLDQyUwlMk2AZ9c2yExA30I3ayWhmqz9tg0DzQ== -rollup-plugin-commonjs@^10.1.0: - version "10.1.0" - resolved "https://registry.yarnpkg.com/rollup-plugin-commonjs/-/rollup-plugin-commonjs-10.1.0.tgz#417af3b54503878e084d127adf4d1caf8beb86fb" - integrity sha512-jlXbjZSQg8EIeAAvepNwhJj++qJWNJw1Cl0YnOqKtP5Djx+fFGkp3WRh+W0ASCaFG5w1jhmzDxgu3SJuVxPF4Q== - dependencies: - estree-walker "^0.6.1" - is-reference "^1.1.2" - magic-string "^0.25.2" - resolve "^1.11.0" - rollup-pluginutils "^2.8.1" - rollup-plugin-node-resolve@^5.2.0: version "5.2.0" resolved "https://registry.yarnpkg.com/rollup-plugin-node-resolve/-/rollup-plugin-node-resolve-5.2.0.tgz#730f93d10ed202473b1fb54a5997a7db8c6d8523" From 9cb65d117dc5b4ef37d1c685c496732ee60ca3d7 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 24 Sep 2021 17:05:09 -0700 Subject: [PATCH 19/36] update --- build/build-bundle.js | 38 ++++++++++++++++++-------------------- build/rollup-plugins.js | 2 +- lighthouse-core/index.js | 7 ------- package.json | 8 ++++---- yarn.lock | 36 ++++++++++++++++++------------------ 5 files changed, 41 insertions(+), 50 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index 9934ea23703f..7b3973d0a60f 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -154,6 +154,7 @@ async function build(entryPath, distPath, opts = {minify: true}) { export {Audit}; `, }), + rollupPlugins.json(), // Currently must run before commonjs (brfs does not support import). // This currenty messes up source maps. rollupPlugins.brfs({ @@ -161,15 +162,12 @@ async function build(entryPath, distPath, opts = {minify: true}) { global: true, parserOpts: {ecmaVersion: 12, sourceType: 'module'}, }), + rollupPlugins.nodePolyfills(), + rollupPlugins.nodeResolve({preferBuiltins: true}), rollupPlugins.commonjs({ // https://github.com/rollup/plugins/issues/922 ignoreGlobal: true, }), - rollupPlugins.json(), - rollupPlugins.nodeResolve({preferBuiltins: true}), - // TODO: ideally would use https://github.com/snowpackjs/rollup-plugin-polyfill-node - // More maintained. also has EventEmitter.off. But it gets rollup errors from commonjs. - rollupPlugins.nodePolyfills(), // Rollup sees the usages of these functions in page functions (ex: see AnchorElements) // and treats them as globals. Because the names are "taken" by the global, Rollup renames // the actual functions (getNodeDetails$1). The page functions expect a certain name, so @@ -181,21 +179,21 @@ async function build(entryPath, distPath, opts = {minify: true}) { [/getRectCenterPoint\$1/, 'getRectCenterPoint'], [/isPositionFixed\$1/, 'isPositionFixed'], ]), - // opts.minify && rollupPlugins.terser({ - // ecma: 2019, - // output: { - // comments: (node, comment) => { - // const text = comment.value; - // if (text.includes('The Lighthouse Authors') && comment.line > 1) return false; - // return /@ts-nocheck - Prevent tsc|@preserve|@license|@cc_on/i.test(text); - // }, - // max_line_len: 1000, - // }, - // // The config relies on class names for gatherers. - // keep_classnames: true, - // // Runtime.evaluate errors if function names are elided. - // keep_fnames: true, - // }), + opts.minify && rollupPlugins.terser({ + ecma: 2019, + output: { + comments: (node, comment) => { + const text = comment.value; + if (text.includes('The Lighthouse Authors') && comment.line > 1) return false; + return /@ts-nocheck - Prevent tsc|@preserve|@license|@cc_on/i.test(text); + }, + max_line_len: 1000, + }, + // The config relies on class names for gatherers. + keep_classnames: true, + // Runtime.evaluate errors if function names are elided. + keep_fnames: true, + }), ], }); diff --git a/build/rollup-plugins.js b/build/rollup-plugins.js index 777e9bfc7530..37fa45165b4d 100644 --- a/build/rollup-plugins.js +++ b/build/rollup-plugins.js @@ -20,7 +20,7 @@ const alias = rollupPluginTypeCoerce(require('@rollup/plugin-alias')); const brfs = require('./rollup-brfs.js'); const commonjs = rollupPluginTypeCoerce(require('@rollup/plugin-commonjs')); const json = rollupPluginTypeCoerce(require('@rollup/plugin-json')); -const nodePolyfills = rollupPluginTypeCoerce(require('rollup-plugin-node-polyfills')); +const nodePolyfills = rollupPluginTypeCoerce(require('rollup-plugin-polyfill-node')); const {nodeResolve} = require('@rollup/plugin-node-resolve'); const postprocess = require('@stadtlandnetz/rollup-plugin-postprocess'); const replace = rollupPluginTypeCoerce(require('rollup-plugin-replace')); diff --git a/lighthouse-core/index.js b/lighthouse-core/index.js index a33bc5cf96eb..373a8cc1eee9 100644 --- a/lighthouse-core/index.js +++ b/lighthouse-core/index.js @@ -5,7 +5,6 @@ */ 'use strict'; -const EventEmitter = require('events'); const Runner = require('./runner.js'); const log = require('lighthouse-logger'); const ChromeProtocol = require('./gather/connections/cri.js'); @@ -13,12 +12,6 @@ const Config = require('./config/config.js'); /** @typedef {import('./gather/connections/connection.js')} Connection */ -// rollup-plugin-node-polyfills does not polyfill EventEmitter.off, -// so do it manually. -if (!EventEmitter.prototype.off) { - EventEmitter.prototype.off = EventEmitter.prototype.removeListener; -} - /* * The relationship between these root modules: * diff --git a/package.json b/package.json index 8837c30ad53b..3862bf4be737 100644 --- a/package.json +++ b/package.json @@ -96,14 +96,14 @@ "@firebase/auth-types": "0.3.2", "@firebase/util": "0.2.1", "@rollup/plugin-alias": "^3.1.2", + "@rollup/plugin-commonjs": "^20.0.0", "@rollup/plugin-dynamic-import-vars": "^1.1.1", "@rollup/plugin-json": "^4.1.0", - "@rollup/plugin-commonjs": "^20.0.0", "@rollup/plugin-node-resolve": "^13.0.4", - "@stadtlandnetz/rollup-plugin-postprocess": "^1.1.0", "@rollup/plugin-typescript": "^8.2.5", - "@testing-library/preact-hooks": "^1.1.0", + "@stadtlandnetz/rollup-plugin-postprocess": "^1.1.0", "@testing-library/preact": "^2.0.1", + "@testing-library/preact-hooks": "^1.1.0", "@types/archiver": "^2.1.2", "@types/browserify": "^12.0.36", "@types/chrome": "^0.0.154", @@ -168,8 +168,8 @@ "puppeteer": "^10.2.0", "rollup": "^2.52.7", "rollup-plugin-brfs": "^1.0.1", - "rollup-plugin-node-polyfills": "^0.2.1", "rollup-plugin-node-resolve": "^5.2.0", + "rollup-plugin-polyfill-node": "^0.7.0", "rollup-plugin-replace": "^2.2.0", "rollup-plugin-shim": "^1.0.0", "rollup-plugin-terser": "^7.0.2", diff --git a/yarn.lock b/yarn.lock index e7c6812aab8a..3851c99f1350 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1259,6 +1259,15 @@ globby "^11.0.1" magic-string "^0.25.7" +"@rollup/plugin-inject@^4.0.0": + version "4.0.2" + resolved "https://registry.yarnpkg.com/@rollup/plugin-inject/-/plugin-inject-4.0.2.tgz#55b21bb244a07675f7fdde577db929c82fc17395" + integrity sha512-TSLMA8waJ7Dmgmoc8JfPnwUwVZgLjjIAM6MqeIFqPO2ODK36JqE0Cf2F54UTgCUuW8da93Mvoj75a6KAVWgylw== + dependencies: + "@rollup/pluginutils" "^3.0.4" + estree-walker "^1.0.1" + magic-string "^0.25.5" + "@rollup/plugin-json@^4.1.0": version "4.1.0" resolved "https://registry.yarnpkg.com/@rollup/plugin-json/-/plugin-json-4.1.0.tgz#54e09867ae6963c593844d8bd7a9c718294496f3" @@ -1286,7 +1295,7 @@ "@rollup/pluginutils" "^3.1.0" resolve "^1.17.0" -"@rollup/pluginutils@^3.0.8", "@rollup/pluginutils@^3.1.0": +"@rollup/pluginutils@^3.0.4", "@rollup/pluginutils@^3.0.8", "@rollup/pluginutils@^3.1.0": version "3.1.0" resolved "https://registry.yarnpkg.com/@rollup/pluginutils/-/pluginutils-3.1.0.tgz#706b4524ee6dc8b103b3c995533e5ad680c02b9b" integrity sha512-GksZ6pr6TpIjHm8h9lSQ8pi8BE9VeubNT0OMJ3B5uZJ8pz73NPiqOtCog/x2/QzM1ENChPKxMDhiQuRHsqc+lg== @@ -6606,7 +6615,7 @@ magic-string@0.25.1: dependencies: sourcemap-codec "^1.4.1" -magic-string@^0.25.2, magic-string@^0.25.3, magic-string@^0.25.7: +magic-string@^0.25.2, magic-string@^0.25.5, magic-string@^0.25.7: version "0.25.7" resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.25.7.tgz#3f497d6fd34c669c6798dcb821f2ef31f5445051" integrity sha512-4CrMT5DOHTDk4HYDlzmwu4FVCcIYI8gauveasrdCu2IKIFOJ3f0v/8MDGJCDL9oD2ppz/Av1b0Nj345H9M+XIA== @@ -8014,22 +8023,6 @@ rollup-plugin-brfs@^1.0.1: dependencies: brfs "^2.0.2" -rollup-plugin-inject@^3.0.0: - version "3.0.2" - resolved "https://registry.yarnpkg.com/rollup-plugin-inject/-/rollup-plugin-inject-3.0.2.tgz#e4233855bfba6c0c12a312fd6649dff9a13ee9f4" - integrity sha512-ptg9PQwzs3orn4jkgXJ74bfs5vYz1NCZlSQMBUA0wKcGp5i5pA1AO3fOUEte8enhGUC+iapTCzEWw2jEFFUO/w== - dependencies: - estree-walker "^0.6.1" - magic-string "^0.25.3" - rollup-pluginutils "^2.8.1" - -rollup-plugin-node-polyfills@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/rollup-plugin-node-polyfills/-/rollup-plugin-node-polyfills-0.2.1.tgz#53092a2744837164d5b8a28812ba5f3ff61109fd" - integrity sha512-4kCrKPTJ6sK4/gLL/U5QzVT8cxJcofO0OU74tnB19F40cmuAKSzH5/siithxlofFEjwvw1YAhPmbvGNA6jEroA== - dependencies: - rollup-plugin-inject "^3.0.0" - rollup-plugin-node-resolve@^5.2.0: version "5.2.0" resolved "https://registry.yarnpkg.com/rollup-plugin-node-resolve/-/rollup-plugin-node-resolve-5.2.0.tgz#730f93d10ed202473b1fb54a5997a7db8c6d8523" @@ -8041,6 +8034,13 @@ rollup-plugin-node-resolve@^5.2.0: resolve "^1.11.1" rollup-pluginutils "^2.8.1" +rollup-plugin-polyfill-node@^0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/rollup-plugin-polyfill-node/-/rollup-plugin-polyfill-node-0.7.0.tgz#938e13278c98a582a4f8814975ddd26f90afddcc" + integrity sha512-iJLZDfvxcQh3SpC0OiYlZG9ik26aRM29hiC2sARbAPXYunB8rzW8GtVaWuJgiCtX1hNAo/OaYvVXfPp15fMs7g== + dependencies: + "@rollup/plugin-inject" "^4.0.0" + rollup-plugin-replace@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/rollup-plugin-replace/-/rollup-plugin-replace-2.2.0.tgz#f41ae5372e11e7a217cde349c8b5d5fd115e70e3" From 2a9968256bfee84b65e195b22cc4ca9157a09534 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Mon, 27 Sep 2021 16:00:13 -0700 Subject: [PATCH 20/36] fix --- build/build-bundle.js | 4 ++-- lighthouse-core/lib/i18n/i18n.js | 14 ++++++++++---- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index 7b3973d0a60f..8e6e0c522958 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -162,12 +162,12 @@ async function build(entryPath, distPath, opts = {minify: true}) { global: true, parserOpts: {ecmaVersion: 12, sourceType: 'module'}, }), - rollupPlugins.nodePolyfills(), - rollupPlugins.nodeResolve({preferBuiltins: true}), rollupPlugins.commonjs({ // https://github.com/rollup/plugins/issues/922 ignoreGlobal: true, }), + rollupPlugins.nodePolyfills(), + rollupPlugins.nodeResolve({preferBuiltins: true}), // Rollup sees the usages of these functions in page functions (ex: see AnchorElements) // and treats them as globals. Because the names are "taken" by the global, Rollup renames // the actual functions (getNodeDetails$1). The page functions expect a certain name, so diff --git a/lighthouse-core/lib/i18n/i18n.js b/lighthouse-core/lib/i18n/i18n.js index 2c054e2e7c65..b0570cacee14 100644 --- a/lighthouse-core/lib/i18n/i18n.js +++ b/lighthouse-core/lib/i18n/i18n.js @@ -8,9 +8,12 @@ /** @typedef {import('../../lib/i18n/locales').LhlMessages} LhlMessages */ const path = require('path'); -const MessageFormat = require('intl-messageformat').default; +const MessageFormat = require('intl-messageformat'); const lookupClosestLocale = require('lookup-closest-locale'); -const LOCALES = require('./locales.js'); +// .default required for rollup bundle to work. +/** @type {import('./locales')} */ +// @ts-expect-error TODO(esmodules): remove when file is es modules. +const LOCALES = require('./locales.js').default || require('./locales.js'); const {isObjectOfUnknownValues, isObjectOrArrayOfUnknownValues} = require('../type-verifiers.js'); const log = require('lighthouse-logger'); const {LH_ROOT} = require('../../../root.js'); @@ -215,7 +218,7 @@ function collectAllCustomElementsFromICU(icuElements, seenElementsById = new Map * Returns a copy of the `values` object, with the values formatted based on how * they will be used in their icuMessage, e.g. KB or milliseconds. The original * object is unchanged. - * @param {MessageFormat} messageFormatter + * @param {MessageFormat.IntlMessageFormat} messageFormatter * @param {Readonly>} values * @param {string} lhlMessage Used for clear error logging. * @return {Record} @@ -291,7 +294,10 @@ function _formatMessage(message, values = {}, locale) { // When using accented english, force the use of a different locale for number formatting. const localeForMessageFormat = (locale === 'en-XA' || locale === 'en-XL') ? 'de-DE' : locale; - const formatter = new MessageFormat(message, localeForMessageFormat, formats); + // This package is not correctly bundled by Rollup. + /** @type {typeof MessageFormat.IntlMessageFormat} */ + const MessageFormatCtor = MessageFormat.IntlMessageFormat || MessageFormat; + const formatter = new MessageFormatCtor(message, localeForMessageFormat, formats); // Preformat values for the message format like KB and milliseconds. const valuesForMessageFormat = _preformatValues(formatter, values, message); From e74eba3997f4b1f1b916efce2eb06065c78a89a3 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Mon, 27 Sep 2021 17:01:39 -0700 Subject: [PATCH 21/36] fix version --- build/build-bundle.js | 3 +- .../lighthouse-successful-run-expected.txt | 82 +++++++++---------- 2 files changed, 42 insertions(+), 43 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index 8e6e0c522958..aac0d186918b 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -120,9 +120,8 @@ async function build(entryPath, distPath, opts = {minify: true}) { shimsObj[modulePath] = 'export default {}'; } - const packageJsonShim = {version: require('../package.json').version}; shimsObj[require.resolve('../package.json')] = - `export default ${JSON.stringify(packageJsonShim)}`; + `export const version = ${JSON.stringify(require('../package.json').version)}`; const bundle = await rollup.rollup({ input: entryPath, diff --git a/third-party/chromium-webtests/webtests/http/tests/devtools/lighthouse/lighthouse-successful-run-expected.txt b/third-party/chromium-webtests/webtests/http/tests/devtools/lighthouse/lighthouse-successful-run-expected.txt index b60c19b2b89e..b95a256ac8d1 100644 --- a/third-party/chromium-webtests/webtests/http/tests/devtools/lighthouse/lighthouse-successful-run-expected.txt +++ b/third-party/chromium-webtests/webtests/http/tests/devtools/lighthouse/lighthouse-successful-run-expected.txt @@ -95,7 +95,7 @@ Gathering in-page: SourceMaps Gathering in-page: FullPageScreenshot Gathering trace Gathering devtoolsLog & network records -Computing artifact: NetworkRecords +Computing artifact: NetworkRecords$I Running afterPass methods Gathering: CSSUsage Gathering: JsUsage @@ -123,8 +123,8 @@ Getting browser version Gathering: TapTargets Gathering: Accessibility Gathering: TraceElements -Computing artifact: ProcessedTrace -Computing artifact: ProcessedNavigation +Computing artifact: ProcessedTrace$f +Computing artifact: ProcessedNavigation$7 Gathering: InspectorIssues Gathering: SourceMaps Gathering: FullPageScreenshot @@ -144,7 +144,7 @@ Navigating to http://127.0.0.1:8000/devtools/lighthouse/resources/lighthouse-bas Running pass methods Gathering in-page: ServiceWorker Gathering devtoolsLog & network records -Computing artifact: NetworkRecords +Computing artifact: NetworkRecords$I Running afterPass methods Gathering: ServiceWorker Running redirectPass pass @@ -160,7 +160,7 @@ Navigating to http://127.0.0.1:8000/devtools/lighthouse/resources/lighthouse-bas Running pass methods Gathering in-page: HTTPRedirect Gathering devtoolsLog & network records -Computing artifact: NetworkRecords +Computing artifact: NetworkRecords$I Running afterPass methods Gathering: HTTPRedirect Disconnecting from browser... @@ -172,50 +172,50 @@ Auditing: Registers a service worker that controls page and `start_url` Auditing: Has a `` tag with `width` or `initial-scale` Computing artifact: ViewportMeta Auditing: First Contentful Paint -Computing artifact: FirstContentfulPaint$1 -Computing artifact: LanternFirstContentfulPaint -Computing artifact: PageDependencyGraph -Computing artifact: LoadSimulator -Computing artifact: NetworkAnalysis +Computing artifact: FirstContentfulPaint$3 +Computing artifact: LanternFirstContentfulPaint$6 +Computing artifact: PageDependencyGraph$a +Computing artifact: LoadSimulator$a +Computing artifact: NetworkAnalysis$1 Auditing: Largest Contentful Paint -Computing artifact: LargestContentfulPaint$1 -Computing artifact: LanternLargestContentfulPaint +Computing artifact: LargestContentfulPaint$2 +Computing artifact: LanternLargestContentfulPaint$1 Auditing: First Meaningful Paint -Computing artifact: FirstMeaningfulPaint$1 -Computing artifact: LanternFirstMeaningfulPaint +Computing artifact: FirstMeaningfulPaint$2 +Computing artifact: LanternFirstMeaningfulPaint$2 Auditing: Speed Index -Computing artifact: SpeedIndex$1 -Computing artifact: LanternSpeedIndex -Computing artifact: Speedline +Computing artifact: SpeedIndex$2 +Computing artifact: LanternSpeedIndex$2 +Computing artifact: Speedline$4 Auditing: Screenshot Thumbnails Auditing: Final Screenshot -Computing artifact: Screenshots +Computing artifact: Screenshots$1 Auditing: Total Blocking Time -Computing artifact: TotalBlockingTime$1 -Computing artifact: LanternTotalBlockingTime -Computing artifact: LanternInteractive +Computing artifact: TotalBlockingTime$2 +Computing artifact: LanternTotalBlockingTime$1 +Computing artifact: LanternInteractive$4 Auditing: Max Potential First Input Delay -Computing artifact: MaxPotentialFID$1 -Computing artifact: LanternMaxPotentialFID +Computing artifact: MaxPotentialFID$2 +Computing artifact: LanternMaxPotentialFID$1 Auditing: Cumulative Layout Shift -Computing artifact: CumulativeLayoutShift$1 +Computing artifact: CumulativeLayoutShift$2 Auditing: No browser errors logged to the console Auditing: Initial server response time was short -Computing artifact: MainResource +Computing artifact: MainResource$g Auditing: Time to Interactive -Computing artifact: Interactive +Computing artifact: Interactive$4 Auditing: User Timing marks and measures Computing artifact: UserTimings$1 Auditing: Avoid chaining critical requests -Computing artifact: CriticalRequestChains$1 +Computing artifact: CriticalRequestChains$2 Auditing: Avoid multiple page redirects Auditing: Web app manifest and service worker meet the installability requirements -Computing artifact: ManifestValues +Computing artifact: ManifestValues$4 Auditing: Provides a valid `apple-touch-icon` Auditing: Configured for a custom splash screen -Computing artifact: ManifestValues +Computing artifact: ManifestValues$4 Auditing: Sets a theme color for the address bar. -Computing artifact: ManifestValues +Computing artifact: ManifestValues$4 Auditing: Manifest has a maskable icon Auditing: Content is sized correctly for the viewport Auditing: Displays images with correct aspect ratio @@ -223,7 +223,7 @@ Auditing: Serves images with appropriate resolution Auditing: Fonts with `font-display: optional` are preloaded Auditing: Avoids deprecated APIs Auditing: Minimizes main-thread work -Computing artifact: MainThreadTasks$1 +Computing artifact: MainThreadTasks$7 Auditing: JavaScript execution time Auditing: Preload key requests Auditing: Preconnect to required origins @@ -234,9 +234,9 @@ Auditing: Network Round Trip Times Auditing: Server Backend Latencies Auditing: Tasks Auditing: Metrics -Computing artifact: TimingSummary +Computing artifact: TimingSummary$1 Auditing: Performance budget -Computing artifact: ResourceSummary$1 +Computing artifact: ResourceSummary$2 Auditing: Timing budget Auditing: Keep request counts low and transfer sizes small Auditing: Minimize third-party usage @@ -254,7 +254,7 @@ Auditing: Ensure CSP is effective against XSS attacks Auditing: Full-page screenshot Auditing: Script Treemap Data Computing artifact: JSBundles -Computing artifact: ModuleDuplication +Computing artifact: ModuleDuplication$2 Auditing: Site works cross-browser Auditing: Page transitions don't feel like they block on the network Auditing: Each page has a URL @@ -316,8 +316,8 @@ Auditing: Uses efficient cache policy on static assets Auditing: Avoids enormous network payloads Auditing: Defer offscreen images Auditing: Eliminate render-blocking resources -Computing artifact: UnusedCSS -Computing artifact: FirstContentfulPaint$1 +Computing artifact: UnusedCSS$3 +Computing artifact: FirstContentfulPaint$3 Auditing: Minify CSS Auditing: Minify JavaScript Auditing: Reduce unused CSS @@ -327,10 +327,10 @@ Auditing: Serve images in next-gen formats Auditing: Efficiently encode images Auditing: Enable text compression Auditing: Properly size images -Computing artifact: ImageRecords +Computing artifact: ImageRecords$1 Auditing: Use video formats for animated content Auditing: Remove duplicate modules in JavaScript bundles -Computing artifact: ModuleDuplication +Computing artifact: ModuleDuplication$2 Computing artifact: JSBundles Auditing: Avoid serving legacy JavaScript to modern browsers Auditing: Avoids Application Cache @@ -360,10 +360,10 @@ Auditing: Document avoids plugins Auditing: Document has a valid `rel=canonical` Auditing: Structured data is valid Auditing: No long tasks blocking ad-related network requests -Computing artifact: LongTasks +Computing artifact: LongTasks$1 Auditing: Minimal render-blocking resources found Auditing: Ad request waterfall -Computing artifact: AdRequestTime +Computing artifact: AdRequestTime$1 Computing artifact: LanternAdRequestTime Auditing: First bid request time Computing artifact: BidRequestTime @@ -373,7 +373,7 @@ Auditing: No ad found at the very top of the viewport Auditing: Few or no ads loaded outside viewport Auditing: Ad tag is loaded asynchronously Auditing: Ads not blocked by load events -Computing artifact: TraceOfTab +Computing artifact: TraceOfTab$1 Auditing: No bottleneck requests found Auditing: No duplicate tags found Auditing: Latency of first ad render From e5d5782fb30dafc8ac22c47890a6b5db079fa4cd Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Mon, 27 Sep 2021 17:14:19 -0700 Subject: [PATCH 22/36] rm old comment --- lighthouse-core/gather/driver/network-monitor.js | 1 - 1 file changed, 1 deletion(-) diff --git a/lighthouse-core/gather/driver/network-monitor.js b/lighthouse-core/gather/driver/network-monitor.js index 2014829e7d6d..778f8a179300 100644 --- a/lighthouse-core/gather/driver/network-monitor.js +++ b/lighthouse-core/gather/driver/network-monitor.js @@ -59,7 +59,6 @@ class NetworkMonitor { this.on = emitter.on.bind(emitter); /** @type {typeof emitter['once']} */ this.once = emitter.once.bind(emitter); - // TODO: rollup bundle doesn't have emitter.off ..... /** @type {typeof emitter['off']} */ this.off = emitter.off.bind(emitter); /** @type {typeof emitter['addListener']} */ From 1741e046f886ff9da5e5a34f98e6ea8863efae09 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Tue, 28 Sep 2021 12:31:20 -0700 Subject: [PATCH 23/36] tweak dt bundle nocheck --- build/build-bundle.js | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index aac0d186918b..cf72fe663c37 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -198,19 +198,16 @@ async function build(entryPath, distPath, opts = {minify: true}) { await bundle.write({ file: distPath, - banner: () => { - let result = banner; - - // Add the banner and modify globals for DevTools if necessary. - if (isDevtools(entryPath) && !DEBUG) { - result += '\n// @ts-nocheck - Prevent tsc stepping into any required bundles.'; - } - - return result; - }, + banner, format: 'iife', sourcemap: DEBUG, }); + + if (isDevtools(entryPath) && !DEBUG) { + const code = fs.readFileSync(distPath); + const newCode = '// @ts-nocheck - Prevent tsc stepping into any required bundles.\n' + code; + fs.writeFileSync(distPath, newCode); + } } /** From b52af24f2ac6316d592e100df2a904dbe8776538 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Tue, 28 Sep 2021 12:45:43 -0700 Subject: [PATCH 24/36] fix --- build/build-bundle.js | 6 ------ lighthouse-cli/test/smokehouse/lighthouse-runners/bundle.js | 6 ++++-- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index cf72fe663c37..8bad2e8c678e 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -202,12 +202,6 @@ async function build(entryPath, distPath, opts = {minify: true}) { format: 'iife', sourcemap: DEBUG, }); - - if (isDevtools(entryPath) && !DEBUG) { - const code = fs.readFileSync(distPath); - const newCode = '// @ts-nocheck - Prevent tsc stepping into any required bundles.\n' + code; - fs.writeFileSync(distPath, newCode); - } } /** diff --git a/lighthouse-cli/test/smokehouse/lighthouse-runners/bundle.js b/lighthouse-cli/test/smokehouse/lighthouse-runners/bundle.js index 41d0689b1458..395312680f19 100644 --- a/lighthouse-cli/test/smokehouse/lighthouse-runners/bundle.js +++ b/lighthouse-cli/test/smokehouse/lighthouse-runners/bundle.js @@ -11,9 +11,12 @@ * Currently uses `lighthouse-dt-bundle.js`. */ +import fs from 'fs'; + import ChromeLauncher from 'chrome-launcher'; import ChromeProtocol from '../../../../lighthouse-core/gather/connections/cri.js'; +import {LH_ROOT} from '../../../../root.js'; const originalRequire = global.require; if (typeof globalThis === 'undefined') { @@ -22,8 +25,7 @@ if (typeof globalThis === 'undefined') { } // Load bundle, which creates a `global.runBundledLighthouse`. -// @ts-ignore - file exists if `yarn build-all` is run, but not used for types anyways. -import '../../../../dist/lighthouse-dt-bundle.js'; // eslint-disable-line +eval(fs.readFileSync(LH_ROOT + '/dist/lighthouse-dt-bundle.js', 'utf-8')); global.require = originalRequire; From 4051326638eef763301479b8e544f4a86c1ee338 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Tue, 28 Sep 2021 13:48:42 -0700 Subject: [PATCH 25/36] fix error in stack pack --- lighthouse-cli/test/smokehouse/smokehouse.js | 2 +- lighthouse-core/lib/stack-packs.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lighthouse-cli/test/smokehouse/smokehouse.js b/lighthouse-cli/test/smokehouse/smokehouse.js index cef142c01cf0..59c616aa3fa4 100644 --- a/lighthouse-cli/test/smokehouse/smokehouse.js +++ b/lighthouse-cli/test/smokehouse/smokehouse.js @@ -215,7 +215,7 @@ function logChildProcessError(localConsole, err) { localConsole.adoptStdStrings(err); } - localConsole.log(log.redify('Error: ') + err.message); + localConsole.log(log.redify('Error: ') + err + '\n' + err.stack); } /** diff --git a/lighthouse-core/lib/stack-packs.js b/lighthouse-core/lib/stack-packs.js index a6556db843ce..caff08769a12 100644 --- a/lighthouse-core/lib/stack-packs.js +++ b/lighthouse-core/lib/stack-packs.js @@ -14,7 +14,7 @@ const i18n = require('./i18n/i18n.js'); * @param {string} module */ function resolve(module) { - if (!require.resolve) { + if (!('resolve' in require)) { return `node_modules/${module}`; } From fb203e106f14bd5bfcf30d34798f23fb99ca91ff Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Tue, 28 Sep 2021 15:16:14 -0700 Subject: [PATCH 26/36] fix mkdir --- build/build-lightrider-bundles.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/build-lightrider-bundles.js b/build/build-lightrider-bundles.js index 6b35b171374e..86744219b6ce 100644 --- a/build/build-lightrider-bundles.js +++ b/build/build-lightrider-bundles.js @@ -22,7 +22,7 @@ const generatorFilename = `./report/generator/report-generator.js`; const entrySourceName = 'lightrider-entry.js'; const entryDistName = 'lighthouse-lr-bundle.js'; -fs.mkdirSync(path.dirname(distDir), {recursive: true}); +fs.mkdirSync(distDir, {recursive: true}); function buildEntryPoint() { const inFile = `${sourceDir}/${entrySourceName}`; From 41512b9e900faf9418b30fd575d0d74c27ebdf23 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Tue, 28 Sep 2021 15:30:03 -0700 Subject: [PATCH 27/36] fix require.main --- build/build-bundle.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/build/build-bundle.js b/build/build-bundle.js index 8bad2e8c678e..53599fbaf16a 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -136,6 +136,8 @@ async function build(entryPath, distPath, opts = {minify: true}) { // This package exports to default in a way that causes Rollup to get confused, // resulting in MessageFormat being undefined. 'require(\'intl-messageformat\').default': 'require(\'intl-messageformat\')', + // Rollup doesn't replace this, so let's manually change it to false. + 'require.main === module': 'false', }, }), rollupPlugins.alias({ From 655c69ceebafd6dd83bd00ae28b0259c6095dabb Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Tue, 28 Sep 2021 15:34:10 -0700 Subject: [PATCH 28/36] globalThis --- build/build-bundle.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/build/build-bundle.js b/build/build-bundle.js index 53599fbaf16a..09b3b5fb71cb 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -138,6 +138,9 @@ async function build(entryPath, distPath, opts = {minify: true}) { 'require(\'intl-messageformat\').default': 'require(\'intl-messageformat\')', // Rollup doesn't replace this, so let's manually change it to false. 'require.main === module': 'false', + // TODO: Use globalThis directly. + 'global.isLightrider': 'globalThis.isLightrider', + 'global.isDevtools': 'globalThis.isDevtools', }, }), rollupPlugins.alias({ From 507e38c744353b69f8bf0138bc0cc2efafd39064 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Tue, 28 Sep 2021 16:24:22 -0700 Subject: [PATCH 29/36] fix smokehouse bundle --- build/build-smokehouse-bundle.js | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/build/build-smokehouse-bundle.js b/build/build-smokehouse-bundle.js index db46639fcaf1..6e53706251ce 100644 --- a/build/build-smokehouse-bundle.js +++ b/build/build-smokehouse-bundle.js @@ -12,19 +12,20 @@ const {LH_ROOT} = require('../root.js'); const distDir = `${LH_ROOT}/dist`; const bundleOutFile = `${distDir}/smokehouse-bundle.js`; const smokehouseLibFilename = './lighthouse-cli/test/smokehouse/frontends/lib.js'; -const smokehouseCliFilename = - require.resolve('../lighthouse-cli/test/smokehouse/lighthouse-runners/cli.js'); +const smokehouseCliFilename = `${LH_ROOT}/lighthouse-cli/test/smokehouse/lighthouse-runners/cli.js`; async function build() { const bundle = await rollup.rollup({ input: smokehouseLibFilename, context: 'globalThis', plugins: [ - rollupPlugins.nodeResolve(), - rollupPlugins.commonjs(), rollupPlugins.shim({ - [smokehouseCliFilename]: 'export default {}', + [smokehouseCliFilename]: + 'export function runLighthouse() { throw new Error("not supported"); }', }), + rollupPlugins.commonjs(), + rollupPlugins.nodePolyfills(), + rollupPlugins.nodeResolve(), ], }); From 806744ce9edbed5149c1d8888cf0649f4ea9c725 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Wed, 29 Sep 2021 12:45:12 -0500 Subject: [PATCH 30/36] Update build/build-bundle.js Co-authored-by: Adam Raine <6752989+adamraine@users.noreply.github.com> --- build/build-bundle.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index 09b3b5fb71cb..894adfff7b2e 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -57,7 +57,7 @@ const banner = ` `.trim(); /** - * Browserify starting at entryPath, writing the minified result to distPath. + * Bundle starting at entryPath, writing the minified result to distPath. * @param {string} entryPath * @param {string} distPath * @param {{minify: boolean}=} opts From 5c91976e499547973048310fa23effd4e3fcbe3d Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 29 Oct 2021 10:37:47 -0700 Subject: [PATCH 31/36] locales --- build/build-bundle.js | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/build/build-bundle.js b/build/build-bundle.js index c826b765a2f4..be723f3cf5a4 100644 --- a/build/build-bundle.js +++ b/build/build-bundle.js @@ -107,13 +107,8 @@ async function build(entryPath, distPath, opts = {minify: true}) { } // Don't include locales in DevTools. - // TODO: can remove when we have rollup brfs. if (isDevtools(entryPath)) { - const localeKeys = Object.keys(require('../shared/localization/locales.js')); - /** @type {Record} */ - const localesShim = {}; - for (const key of localeKeys) localesShim[key] = {}; - shimsObj['./locales.js'] = `export default ${JSON.stringify(localesShim)}`; + shimsObj['./locales.js'] = 'export default {}'; } for (const modulePath of modulesToIgnore) { @@ -183,7 +178,7 @@ async function build(entryPath, distPath, opts = {minify: true}) { comments: (node, comment) => { const text = comment.value; if (text.includes('The Lighthouse Authors') && comment.line > 1) return false; - return /@ts-nocheck - Prevent tsc|@preserve|@license|@cc_on/i.test(text); + return /@ts-nocheck - Prevent tsc|@preserve|@license|@cc_on|^!/i.test(text); }, max_line_len: 1000, }, From 37065bf1bd28c72cda5cfa22c4d6b53b9303e172 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 29 Oct 2021 16:46:59 -0700 Subject: [PATCH 32/36] attempt fix --- clients/devtools-entry.js | 4 ++++ clients/lightrider/lightrider-entry.js | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/clients/devtools-entry.js b/clients/devtools-entry.js index 6869e00f2dd2..ebe009aadbef 100644 --- a/clients/devtools-entry.js +++ b/clients/devtools-entry.js @@ -14,6 +14,10 @@ const constants = require('../lighthouse-core/config/constants.js'); /** @typedef {import('../lighthouse-core/gather/connections/connection.js')} Connection */ +// Rollup seems to overlook some references to `Buffer`, so it must be made explicit. +// (`parseSourceMapFromDataUrl` breaks without this) +global.Buffer = require('buffer').Buffer; + /** * Returns a config, which runs only certain categories. * Varies the config to use based on device. diff --git a/clients/lightrider/lightrider-entry.js b/clients/lightrider/lightrider-entry.js index 9778337533f5..6c9cfb4f7634 100644 --- a/clients/lightrider/lightrider-entry.js +++ b/clients/lightrider/lightrider-entry.js @@ -19,6 +19,10 @@ const LR_PRESETS = { /** @typedef {import('../../lighthouse-core/gather/connections/connection.js')} Connection */ +// Rollup seems to overlook some references to `Buffer`, so it must be made explicit. +// (`parseSourceMapFromDataUrl` breaks without this) +global.Buffer = require('buffer').Buffer; + /** * Run lighthouse for connection and provide similar results as in CLI. * From 3f57709a32b989830d99c6e45e158d8bd564d392 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 29 Oct 2021 16:51:22 -0700 Subject: [PATCH 33/36] oops --- clients/devtools-entry.js | 5 ++++- clients/lightrider/lightrider-entry.js | 4 +++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/clients/devtools-entry.js b/clients/devtools-entry.js index ebe009aadbef..9e4bb7ded52c 100644 --- a/clients/devtools-entry.js +++ b/clients/devtools-entry.js @@ -5,6 +5,8 @@ */ 'use strict'; +/* global globalThis */ + const lighthouse = require('../lighthouse-core/index.js'); const RawProtocol = require('../lighthouse-core/gather/connections/raw.js'); const log = require('lighthouse-logger'); @@ -16,7 +18,8 @@ const constants = require('../lighthouse-core/config/constants.js'); // Rollup seems to overlook some references to `Buffer`, so it must be made explicit. // (`parseSourceMapFromDataUrl` breaks without this) -global.Buffer = require('buffer').Buffer; +// @ts-expect-error +globalThis.Buffer = require('buffer').Buffer; /** * Returns a config, which runs only certain categories. diff --git a/clients/lightrider/lightrider-entry.js b/clients/lightrider/lightrider-entry.js index 6c9cfb4f7634..8859c2072efb 100644 --- a/clients/lightrider/lightrider-entry.js +++ b/clients/lightrider/lightrider-entry.js @@ -5,6 +5,8 @@ */ 'use strict'; +/* global globalThis */ + const lighthouse = require('../../lighthouse-core/index.js'); const LHError = require('../../lighthouse-core/lib/lh-error.js'); @@ -21,7 +23,7 @@ const LR_PRESETS = { // Rollup seems to overlook some references to `Buffer`, so it must be made explicit. // (`parseSourceMapFromDataUrl` breaks without this) -global.Buffer = require('buffer').Buffer; +globalThis.Buffer = require('buffer').Buffer; /** * Run lighthouse for connection and provide similar results as in CLI. From f4494ab770e16de1aceda9db2858d88efac3db83 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 29 Oct 2021 17:03:34 -0700 Subject: [PATCH 34/36] test source-maps bundled --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 3a363e93e814..0d264048988f 100644 --- a/package.json +++ b/package.json @@ -37,7 +37,7 @@ "start": "yarn build-report --standalone && node ./lighthouse-cli/index.js", "jest": "node --experimental-vm-modules ./node_modules/jest/bin/jest.js", "test": "yarn diff:sample-json && yarn lint --quiet && yarn unit && yarn type-check", - "test-bundle": "yarn smoke --runner bundle -j=1 --retries=2 a11y dbw", + "test-bundle": "yarn smoke --runner bundle -j=1 --retries=2 a11y dbw source-maps", "test-clients": "yarn jest \"$PWD/clients/\" && yarn jest --testMatch=\"**/clients/test/**/*-test-pptr.js\"", "test-viewer": "yarn unit-viewer && yarn jest --testMatch=\"**/viewer/**/*-test-pptr.js\"", "test-treemap": "yarn unit-treemap && yarn jest --testMatch=\"**/treemap/**/*-test-pptr.js\"", From 0b6d25c508f23951f88e0c4aaa2a805cf3c914bf Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 29 Oct 2021 17:15:48 -0700 Subject: [PATCH 35/36] fix type --- clients/devtools-entry.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clients/devtools-entry.js b/clients/devtools-entry.js index 9e4bb7ded52c..21299cf96139 100644 --- a/clients/devtools-entry.js +++ b/clients/devtools-entry.js @@ -18,7 +18,7 @@ const constants = require('../lighthouse-core/config/constants.js'); // Rollup seems to overlook some references to `Buffer`, so it must be made explicit. // (`parseSourceMapFromDataUrl` breaks without this) -// @ts-expect-error +/** @type {BufferConstructor} */ globalThis.Buffer = require('buffer').Buffer; /** From 38cac7e25db3379939d77e6fe7470a4253255cb8 Mon Sep 17 00:00:00 2001 From: Connor Clark Date: Fri, 29 Oct 2021 17:22:46 -0700 Subject: [PATCH 36/36] ok --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 0d264048988f..40f0000b1384 100644 --- a/package.json +++ b/package.json @@ -37,7 +37,7 @@ "start": "yarn build-report --standalone && node ./lighthouse-cli/index.js", "jest": "node --experimental-vm-modules ./node_modules/jest/bin/jest.js", "test": "yarn diff:sample-json && yarn lint --quiet && yarn unit && yarn type-check", - "test-bundle": "yarn smoke --runner bundle -j=1 --retries=2 a11y dbw source-maps", + "test-bundle": "yarn smoke --runner bundle -j=1 --retries=2 --invert-match forms", "test-clients": "yarn jest \"$PWD/clients/\" && yarn jest --testMatch=\"**/clients/test/**/*-test-pptr.js\"", "test-viewer": "yarn unit-viewer && yarn jest --testMatch=\"**/viewer/**/*-test-pptr.js\"", "test-treemap": "yarn unit-treemap && yarn jest --testMatch=\"**/treemap/**/*-test-pptr.js\"",