@types/node 14.18.30 → 14.18.32

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 v14.18/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/v14.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Fri, 23 Sep 2022 18:33:23 GMT
11
+ * Last updated: Mon, 10 Oct 2022 21:33:34 GMT
12
12
  * Dependencies: none
13
13
  * Global values: `AbortController`, `AbortSignal`, `Buffer`, `__dirname`, `__filename`, `clearImmediate`, `clearInterval`, `clearTimeout`, `console`, `exports`, `global`, `module`, `process`, `queueMicrotask`, `require`, `setImmediate`, `setInterval`, `setTimeout`
14
14
 
node v14.18/http.d.ts CHANGED
@@ -548,6 +548,25 @@ declare module 'http' {
548
548
  ): ClientRequest;
549
549
  function get(options: RequestOptions | string | URL, callback?: (res: IncomingMessage) => void): ClientRequest;
550
550
  function get(url: string | URL, options: RequestOptions, callback?: (res: IncomingMessage) => void): ClientRequest;
551
+
552
+ /**
553
+ * Performs the low-level validations on the provided name that are done when `res.setHeader(name, value)` is called.
554
+ * Passing illegal value as name will result in a TypeError being thrown, identified by `code: 'ERR_INVALID_HTTP_TOKEN'`.
555
+ * @param name Header name
556
+ * @since v14.3.0
557
+ */
558
+ function validateHeaderName(name: string): void;
559
+ /**
560
+ * Performs the low-level validations on the provided value that are done when `res.setHeader(name, value)` is called.
561
+ * Passing illegal value as value will result in a TypeError being thrown.
562
+ * - Undefined value error is identified by `code: 'ERR_HTTP_INVALID_HEADER_VALUE'`.
563
+ * - Invalid value character error is identified by `code: 'ERR_INVALID_CHAR'`.
564
+ * @param name Header name
565
+ * @param value Header value
566
+ * @since v14.3.0
567
+ */
568
+ function validateHeaderValue(name: string, value: string): void;
569
+
551
570
  let globalAgent: Agent;
552
571
 
553
572
  /**
node v14.18/os.d.ts CHANGED
@@ -21,6 +21,7 @@ declare module 'os' {
21
21
 
22
22
  interface NetworkInterfaceInfoIPv4 extends NetworkInterfaceBase {
23
23
  family: "IPv4";
24
+ scopeid?: undefined;
24
25
  }
25
26
 
26
27
  interface NetworkInterfaceInfoIPv6 extends NetworkInterfaceBase {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "14.18.30",
3
+ "version": "14.18.32",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -227,6 +227,6 @@
227
227
  },
228
228
  "scripts": {},
229
229
  "dependencies": {},
230
- "typesPublisherContentHash": "e1bcce1cd1a146753316480d13a7820cbb2367abb776001a54e033fcfd53652b",
230
+ "typesPublisherContentHash": "dc34a71dfe14ccd84c65e67272875f0c481b754fb1306d2d07712ee664154e50",
231
231
  "typeScriptVersion": "4.1"
232
232
  }
@@ -548,6 +548,25 @@ declare module 'http' {
548
548
  ): ClientRequest;
549
549
  function get(options: RequestOptions | string | URL, callback?: (res: IncomingMessage) => void): ClientRequest;
550
550
  function get(url: string | URL, options: RequestOptions, callback?: (res: IncomingMessage) => void): ClientRequest;
551
+
552
+ /**
553
+ * Performs the low-level validations on the provided name that are done when `res.setHeader(name, value)` is called.
554
+ * Passing illegal value as name will result in a TypeError being thrown, identified by `code: 'ERR_INVALID_HTTP_TOKEN'`.
555
+ * @param name Header name
556
+ * @since v14.3.0
557
+ */
558
+ function validateHeaderName(name: string): void;
559
+ /**
560
+ * Performs the low-level validations on the provided value that are done when `res.setHeader(name, value)` is called.
561
+ * Passing illegal value as value will result in a TypeError being thrown.
562
+ * - Undefined value error is identified by `code: 'ERR_HTTP_INVALID_HEADER_VALUE'`.
563
+ * - Invalid value character error is identified by `code: 'ERR_INVALID_CHAR'`.
564
+ * @param name Header name
565
+ * @param value Header value
566
+ * @since v14.3.0
567
+ */
568
+ function validateHeaderValue(name: string, value: string): void;
569
+
551
570
  let globalAgent: Agent;
552
571
 
553
572
  /**
@@ -21,6 +21,7 @@ declare module 'os' {
21
21
 
22
22
  interface NetworkInterfaceInfoIPv4 extends NetworkInterfaceBase {
23
23
  family: "IPv4";
24
+ scopeid?: undefined;
24
25
  }
25
26
 
26
27
  interface NetworkInterfaceInfoIPv6 extends NetworkInterfaceBase {