@types/node 14.0.26 → 14.6.2

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/README.md CHANGED
@@ -8,9 +8,9 @@ This package contains type definitions for Node.js (http://nodejs.org/).
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Fri, 24 Jul 2020 19:02:01 GMT
11
+ * Last updated: Fri, 28 Aug 2020 23:18:14 GMT
12
12
  * Dependencies: none
13
- * Global values: `Buffer`, `Symbol`, `__dirname`, `__filename`, `clearImmediate`, `clearInterval`, `clearTimeout`, `exports`, `global`, `module`, `queueMicrotask`, `require`, `setImmediate`, `setInterval`, `setTimeout`
13
+ * Global values: `Buffer`, `Symbol`, `__dirname`, `__filename`, `clearImmediate`, `clearInterval`, `clearTimeout`, `console`, `exports`, `global`, `module`, `process`, `queueMicrotask`, `require`, `setImmediate`, `setInterval`, `setTimeout`
14
14
 
15
15
  # Credits
16
16
  These definitions were written by [Microsoft TypeScript](https://github.com/Microsoft), [DefinitelyTyped](https://github.com/DefinitelyTyped), [Alberto Schiabel](https://github.com/jkomyno), [Alexander T.](https://github.com/a-tarasyuk), [Alvis HT Tang](https://github.com/alvis), [Andrew Makarov](https://github.com/r3nya), [Benjamin Toueg](https://github.com/btoueg), [Bruno Scheufler](https://github.com/brunoscheufler), [Chigozirim C.](https://github.com/smac89), [David Junger](https://github.com/touffy), [Deividas Bakanas](https://github.com/DeividasBakanas), [Eugene Y. Q. Shen](https://github.com/eyqs), [Flarna](https://github.com/Flarna), [Hannes Magnusson](https://github.com/Hannes-Magnusson-CK), [Hoàng Văn Khải](https://github.com/KSXGitHub), [Huw](https://github.com/hoo29), [Kelvin Jin](https://github.com/kjin), [Klaus Meinhardt](https://github.com/ajafff), [Lishude](https://github.com/islishude), [Mariusz Wiktorczyk](https://github.com/mwiktorczyk), [Mohsen Azimi](https://github.com/mohsen1), [Nicolas Even](https://github.com/n-e), [Nikita Galkin](https://github.com/galkin), [Parambir Singh](https://github.com/parambirs), [Sebastian Silbermann](https://github.com/eps1lon), [Simon Schick](https://github.com/SimonSchick), [Thomas den Hollander](https://github.com/ThomasdenH), [Wilco Bakker](https://github.com/WilcoBakker), [wwwy3y3](https://github.com/wwwy3y3), [Samuel Ainsworth](https://github.com/samuela), [Kyle Uehlein](https://github.com/kuehlein), [Jordi Oliveras Rovira](https://github.com/j-oliveras), [Thanik Bhongbhibhat](https://github.com/bhongy), [Marcin Kopacz](https://github.com/chyzwar), [Trivikram Kamat](https://github.com/trivikr), [Minh Son Nguyen](https://github.com/nguymin4), [Junxiao Shi](https://github.com/yoursunny), [Ilia Baryshnikov](https://github.com/qwelias), [ExE Boss](https://github.com/ExE-Boss), [Surasak Chaisurin](https://github.com/Ryan-Willpower), [Piotr Błażejewicz](https://github.com/peterblazejewicz), [Anna Henningsen](https://github.com/addaleax), and [Jason Kwok](https://github.com/JasonHK).
node/async_hooks.d.ts CHANGED
@@ -152,8 +152,7 @@ declare module "async_hooks" {
152
152
  /**
153
153
  * This method disables the instance of `AsyncLocalStorage`. All subsequent calls
154
154
  * to `asyncLocalStorage.getStore()` will return `undefined` until
155
- * `asyncLocalStorage.run()` or `asyncLocalStorage.runSyncAndReturn()`
156
- * is called again.
155
+ * `asyncLocalStorage.run()` is called again.
157
156
  *
158
157
  * When calling `asyncLocalStorage.disable()`, all current contexts linked to the
159
158
  * instance will be exited.
@@ -169,45 +168,40 @@ declare module "async_hooks" {
169
168
  disable(): void;
170
169
 
171
170
  /**
172
- * This method returns the current store.
173
- * If this method is called outside of an asynchronous context initialized by
174
- * calling `asyncLocalStorage.run` or `asyncLocalStorage.runAndReturn`, it will
171
+ * This method returns the current store. If this method is called outside of an
172
+ * asynchronous context initialized by calling `asyncLocalStorage.run`, it will
175
173
  * return `undefined`.
176
174
  */
177
175
  getStore(): T | undefined;
178
176
 
179
177
  /**
180
- * Calling `asyncLocalStorage.run(callback)` will create a new asynchronous
181
- * context.
182
- * Within the callback function and the asynchronous operations from the callback,
183
- * `asyncLocalStorage.getStore()` will return an instance of `Map` known as
184
- * "the store". This store will be persistent through the following
185
- * asynchronous calls.
178
+ * This methods runs a function synchronously within a context and return its
179
+ * return value. The store is not accessible outside of the callback function or
180
+ * the asynchronous operations created within the callback.
186
181
  *
187
- * The callback will be ran asynchronously. Optionally, arguments can be passed
188
- * to the function. They will be passed to the callback function.
182
+ * Optionally, arguments can be passed to the function. They will be passed to the
183
+ * callback function.
189
184
  *
190
- * If an error is thrown by the callback function, it will not be caught by
191
- * a `try/catch` block as the callback is ran in a new asynchronous resource.
192
- * Also, the stacktrace will be impacted by the asynchronous call.
185
+ * I the callback function throws an error, it will be thrown by `run` too. The
186
+ * stacktrace will not be impacted by this call and the context will be exited.
193
187
  */
194
188
  // TODO: Apply generic vararg once available
195
- run(store: T, callback: (...args: any[]) => void, ...args: any[]): void;
189
+ run<R>(store: T, callback: (...args: any[]) => R, ...args: any[]): R;
196
190
 
197
191
  /**
198
- * Calling `asyncLocalStorage.exit(callback)` will create a new asynchronous
199
- * context.
200
- * Within the callback function and the asynchronous operations from the callback,
201
- * `asyncLocalStorage.getStore()` will return `undefined`.
192
+ * This methods runs a function synchronously outside of a context and return its
193
+ * return value. The store is not accessible within the callback function or the
194
+ * asynchronous operations created within the callback.
202
195
  *
203
- * The callback will be ran asynchronously. Optionally, arguments can be passed
204
- * to the function. They will be passed to the callback function.
196
+ * Optionally, arguments can be passed to the function. They will be passed to the
197
+ * callback function.
205
198
  *
206
- * If an error is thrown by the callback function, it will not be caught by
207
- * a `try/catch` block as the callback is ran in a new asynchronous resource.
208
- * Also, the stacktrace will be impacted by the asynchronous call.
199
+ * If the callback function throws an error, it will be thrown by `exit` too. The
200
+ * stacktrace will not be impacted by this call and the context will be
201
+ * re-entered.
209
202
  */
210
- exit(callback: (...args: any[]) => void, ...args: any[]): void;
203
+ // TODO: Apply generic vararg once available
204
+ exit<R>(callback: (...args: any[]) => R, ...args: any[]): R;
211
205
 
212
206
  /**
213
207
  * Calling `asyncLocalStorage.enterWith(store)` will transition into the context
node/globals.d.ts CHANGED
@@ -36,6 +36,9 @@ interface NodeRequire extends NodeJS.Require {}
36
36
  interface RequireResolve extends NodeJS.RequireResolve {}
37
37
  interface NodeModule extends NodeJS.Module {}
38
38
 
39
+ declare var process: NodeJS.Process;
40
+ declare var console: Console;
41
+
39
42
  declare var __filename: string;
40
43
  declare var __dirname: string;
41
44
 
node/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- // Type definitions for non-npm package Node.js 14.0
1
+ // Type definitions for non-npm package Node.js 14.6
2
2
  // Project: http://nodejs.org/
3
3
  // Definitions by: Microsoft TypeScript <https://github.com/Microsoft>
4
4
  // DefinitelyTyped <https://github.com/DefinitelyTyped>
node/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "14.0.26",
3
+ "version": "14.6.2",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "license": "MIT",
6
6
  "contributors": [
@@ -246,6 +246,6 @@
246
246
  },
247
247
  "scripts": {},
248
248
  "dependencies": {},
249
- "typesPublisherContentHash": "84663a04233bed9c933d13792d95d0a6232a960e6a142e6c698b7e79a30daee3",
250
- "typeScriptVersion": "3.0"
249
+ "typesPublisherContentHash": "620e9539262c91f3c15049d0573e059eae23dd73a2c3b31b853e7fe027cfebb9",
250
+ "typeScriptVersion": "3.1"
251
251
  }
node/process.d.ts CHANGED
@@ -32,7 +32,7 @@ declare module "process" {
32
32
  lts?: string;
33
33
  }
34
34
 
35
- interface ProcessVersions {
35
+ interface ProcessVersions extends Dict<string> {
36
36
  http_parser: string;
37
37
  node: string;
38
38
  v8: string;
node/tls.d.ts CHANGED
@@ -706,6 +706,15 @@ declare module "tls" {
706
706
  * shared between applications. Unused by clients.
707
707
  */
708
708
  sessionIdContext?: string;
709
+ /**
710
+ * 48 bytes of cryptographically strong pseudo-random data.
711
+ */
712
+ ticketKeys?: Buffer;
713
+ /**
714
+ * The number of seconds after which a TLS session created by the server
715
+ * will no longer be resumable.
716
+ */
717
+ sessionTimeout?: number;
709
718
  }
710
719
 
711
720
  interface SecureContext {
node/vm.d.ts CHANGED
@@ -41,6 +41,10 @@ declare module "vm" {
41
41
  * Default: `false`.
42
42
  */
43
43
  breakOnSigint?: boolean;
44
+ /**
45
+ * If set to `afterEvaluate`, microtasks will be run immediately after the script has run.
46
+ */
47
+ microtaskMode?: 'afterEvaluate';
44
48
  }
45
49
  interface CompileFunctionOptions extends BaseOptions {
46
50
  /**
node/worker_threads.d.ts CHANGED
@@ -75,6 +75,7 @@ declare module "worker_threads" {
75
75
  * Additional data to send in the first worker message.
76
76
  */
77
77
  transferList?: Array<ArrayBuffer | MessagePort>;
78
+ trackUnmanagedFds?: boolean;
78
79
  }
79
80
 
80
81
  interface ResourceLimits {