@types/node 16.11.21 → 16.11.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
node v16.11/README.md CHANGED
@@ -8,7 +8,7 @@ This package contains type definitions for Node.js (https://nodejs.org/).
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node/v16.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Tue, 18 Jan 2022 18:31:38 GMT
11
+ * Last updated: Tue, 01 Feb 2022 08:31:30 GMT
12
12
  * Dependencies: none
13
13
  * Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`
14
14
 
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "16.11.21",
3
+ "version": "16.11.22",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -220,6 +220,6 @@
220
220
  },
221
221
  "scripts": {},
222
222
  "dependencies": {},
223
- "typesPublisherContentHash": "3db0872e58d9ad501f72a82401c2e041d36a2f89d7a1814c45b4caa8548af727",
223
+ "typesPublisherContentHash": "57a94e60cf640ea4d81b4fa914f3fb5929a63ae0b4d5141d7daf250c569e7d10",
224
224
  "typeScriptVersion": "3.8"
225
225
  }
node v16.11/url.d.ts CHANGED
@@ -738,7 +738,7 @@ declare module 'url' {
738
738
  * @param fn Invoked for each name-value pair in the query
739
739
  * @param thisArg To be used as `this` value for when `fn` is called
740
740
  */
741
- forEach<TThis = this>(callback: (this: TThis, value: string, name: string, searchParams: this) => void, thisArg?: TThis): void;
741
+ forEach<TThis = this>(callback: (this: TThis, value: string, name: string, searchParams: URLSearchParams) => void, thisArg?: TThis): void;
742
742
  /**
743
743
  * Returns the value of the first name-value pair whose name is `name`. If there
744
744
  * are no such pairs, `null` is returned.
@@ -815,6 +815,32 @@ declare module 'url' {
815
815
  values(): IterableIterator<string>;
816
816
  [Symbol.iterator](): IterableIterator<[string, string]>;
817
817
  }
818
+
819
+ import { URL as _URL, URLSearchParams as _URLSearchParams } from 'url';
820
+ global {
821
+ interface URLSearchParams extends _URLSearchParams {}
822
+ interface URL extends _URL {}
823
+ interface Global {
824
+ URL: typeof _URL;
825
+ URLSearchParams: typeof _URLSearchParams;
826
+ }
827
+ /**
828
+ * `URL` class is a global reference for `require('url').URL`
829
+ * https://nodejs.org/api/url.html#the-whatwg-url-api
830
+ * @since v10.0.0
831
+ */
832
+ var URL: typeof globalThis extends { webkitURL: infer URL } ? URL : typeof _URL;
833
+ /**
834
+ * `URLSearchParams` class is a global reference for `require('url').URLSearchParams`.
835
+ * https://nodejs.org/api/url.html#class-urlsearchparams
836
+ * @since v10.0.0
837
+ */
838
+ var URLSearchParams: {
839
+ prototype: URLSearchParams;
840
+ new(init?: string[][] | Record<string, string> | string | URLSearchParams): URLSearchParams;
841
+ toString(): string;
842
+ };
843
+ }
818
844
  }
819
845
  declare module 'node:url' {
820
846
  export * from 'url';