@types/node 12.20.42 → 12.20.43

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 v12.20/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/v12.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Mon, 17 Jan 2022 09:01:30 GMT
11
+ * Last updated: Tue, 01 Feb 2022 08:31:32 GMT
12
12
  * Dependencies: none
13
13
  * Global values: `Buffer`, `NodeJS`, `__dirname`, `__filename`, `clearImmediate`, `clearInterval`, `clearTimeout`, `console`, `exports`, `global`, `module`, `process`, `queueMicrotask`, `require`, `setImmediate`, `setInterval`, `setTimeout`
14
14
 
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "12.20.42",
3
+ "version": "12.20.43",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -190,6 +190,6 @@
190
190
  },
191
191
  "scripts": {},
192
192
  "dependencies": {},
193
- "typesPublisherContentHash": "38e884548ed8d9aa2c390da02b72d66f32d2a9b9b46bda93a50fac13369bcb95",
193
+ "typesPublisherContentHash": "65840c8a980bb0fee8cb5a1fd1376e2c9859f6258e8936b87c4f57d16119945c",
194
194
  "typeScriptVersion": "3.8"
195
195
  }
node v12.20/url.d.ts CHANGED
@@ -103,7 +103,7 @@ declare module 'url' {
103
103
  append(name: string, value: string): void;
104
104
  delete(name: string): void;
105
105
  entries(): IterableIterator<[string, string]>;
106
- forEach(callback: (value: string, name: string, searchParams: this) => void): void;
106
+ forEach(callback: (value: string, name: string, searchParams: URLSearchParams) => void): void;
107
107
  get(name: string): string | null;
108
108
  getAll(name: string): string[];
109
109
  has(name: string): boolean;
@@ -114,4 +114,30 @@ declare module 'url' {
114
114
  values(): IterableIterator<string>;
115
115
  [Symbol.iterator](): IterableIterator<[string, string]>;
116
116
  }
117
+
118
+ import { URL as _URL, URLSearchParams as _URLSearchParams } from 'url';
119
+ global {
120
+ interface URLSearchParams extends _URLSearchParams {}
121
+ interface URL extends _URL {}
122
+ interface Global {
123
+ URL: typeof _URL;
124
+ URLSearchParams: typeof _URLSearchParams;
125
+ }
126
+ /**
127
+ * `URL` class is a global reference for `require('url').URL`
128
+ * https://nodejs.org/api/url.html#the-whatwg-url-api
129
+ * @since v10.0.0
130
+ */
131
+ var URL: typeof globalThis extends { webkitURL: infer URL } ? URL : typeof _URL;
132
+ /**
133
+ * `URLSearchParams` class is a global reference for `require('url').URLSearchParams`.
134
+ * https://nodejs.org/api/url.html#class-urlsearchparams
135
+ * @since v10.0.0
136
+ */
137
+ var URLSearchParams: {
138
+ prototype: URLSearchParams;
139
+ new(init?: string[][] | Record<string, string> | string | URLSearchParams): URLSearchParams;
140
+ toString(): string;
141
+ };
142
+ }
117
143
  }