Skip to content

Commit

Permalink
trying to update
Browse files Browse the repository at this point in the history
  • Loading branch information
connorjclark committed Jun 27, 2024
1 parent e0be820 commit 128f26e
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 28 deletions.
1 change: 1 addition & 0 deletions build/process-global.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import process from 'process';

// eslint-disable-next-line no-undef
// @ts-expect-error
globalThis.process = process;
5 changes: 2 additions & 3 deletions core/scripts/i18n/collect-strings.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ const ignoredPathComponents = [

/**
* Extract the description and examples (if any) from a jsDoc annotation.
* @param {import('typescript').JSDoc|undefined} ast
* @param {import('typescript').JSDoc|import('typescript').JSDocTag|undefined} ast
* @param {string} message
* @return {{description: string, examples: Record<string, string>}}
*/
Expand All @@ -67,7 +67,7 @@ function computeDescription(ast, message) {
throw Error(`Missing description comment for message "${message}"`);
}

if (ast.tags) {
if ('tags' in ast && ast.tags) {
// This is a complex description with description and examples.
let description = '';
/** @type {Record<string, string>} */
Expand Down Expand Up @@ -520,7 +520,6 @@ function parseUIStrings(sourceStr, liveUIStrings) {
// Use live message to avoid having to e.g. concat strings broken into parts.
const message = (liveUIStrings[key]);

// @ts-expect-error - Not part of the public tsc interface yet.
const jsDocComments = tsc.getJSDocCommentsAndTags(property);
const {description, examples} = computeDescription(jsDocComments[0], message);

Expand Down
1 change: 1 addition & 0 deletions core/test/gather/driver/network-monitor-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ describe('NetworkMonitor', () => {
]);

// Bring the starting events forward in the log.
/** @type {LH.Protocol.RawEventMessage[]} */
const startEvents = log.filter(m => m.method === 'Network.requestWillBeSent');
const restEvents = log.filter(m => !startEvents.includes(m));
return [...startEvents, ...restEvents];
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@
"terser": "^5.18.2",
"testdouble": "^3.18.0",
"typed-query-selector": "^2.11.2",
"typescript": "^5.0.4",
"typescript": "5.5.2",
"wait-for-expect": "^3.0.2",
"webtreemap-cdt": "^3.2.1"
},
Expand Down
11 changes: 0 additions & 11 deletions report/types/augment-dom.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,3 @@

// Import to augment querySelector/querySelectorAll with stricter type checking.
import '../../types/internal/query-selector';

declare global {
var CompressionStream: {
prototype: CompressionStream,
new (format: string): CompressionStream,
};

interface CompressionStream extends GenericTransformStream {
readonly format: string;
}
}
6 changes: 0 additions & 6 deletions types/internal/node.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,6 @@ declare global {
var isDevtools: boolean | undefined;
var isLightrider: boolean | undefined;

// Augment Intl to include
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/getCanonicalLocales
namespace Intl {
var getCanonicalLocales: (locales?: string | Array<string>) => Array<string>;
}

// Some functions defined in node are stringified and run in the browser.
// Ensure those functions are working with the correct browser environment.
interface Window {
Expand Down
21 changes: 14 additions & 7 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1489,9 +1489,11 @@
integrity sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA==

"@types/node@*", "@types/node@>=12.12.47", "@types/node@>=13.7.0":
version "16.18.11"
resolved "https://registry.yarnpkg.com/@types/node/-/node-16.18.11.tgz#cbb15c12ca7c16c85a72b6bdc4d4b01151bb3cae"
integrity sha512-3oJbGBUWuS6ahSnEq1eN2XrCyf4YsWI8OyCvo7c64zQJNplk3mO84t53o8lfTk+2ji59g5ycfc6qQ3fdHliHuA==
version "20.14.9"
resolved "https://registry.yarnpkg.com/@types/node/-/node-20.14.9.tgz#12e8e765ab27f8c421a1820c99f5f313a933b420"
integrity sha512-06OCtnTXtWOZBJlRApleWndH4JsRVs1pDCc8dLSQp+7PpUpX3ePdHyeNSFTeSe7FtKyQkrlPvHwJOW3SLd8Oyg==
dependencies:
undici-types "~5.26.4"

"@types/node@^11.10.4":
version "11.15.54"
Expand Down Expand Up @@ -7179,10 +7181,10 @@ typedarray-to-buffer@^3.1.5:
dependencies:
is-typedarray "^1.0.0"

typescript@^5.0.4:
version "5.0.4"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.0.4.tgz#b217fd20119bd61a94d4011274e0ab369058da3b"
integrity sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw==
typescript@5.5.2:
version "5.5.2"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.5.2.tgz#c26f023cb0054e657ce04f72583ea2d85f8d0507"
integrity sha512-NcRtPEOsPFFWjobJEtfihkLCZCXZt/os3zf8nTxjVH3RvTSxjrCamJpbExGvYOF+tFHc3pA65qpdwPbzjohhew==

uglify-js@^3.1.4:
version "3.14.4"
Expand All @@ -7207,6 +7209,11 @@ [email protected]:
buffer "^5.2.1"
through "^2.3.8"

undici-types@~5.26.4:
version "5.26.5"
resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-5.26.5.tgz#bcd539893d00b56e964fd2657a4866b221a65617"
integrity sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==

union-value@^1.0.0:
version "1.0.1"
resolved "https://registry.yarnpkg.com/union-value/-/union-value-1.0.1.tgz#0b6fe7b835aecda61c6ea4d4f02c14221e109847"
Expand Down

0 comments on commit 128f26e

Please sign in to comment.