@types/node 16.18.74 → 16.18.75

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.18/README.md CHANGED
@@ -8,7 +8,7 @@ This package contains type definitions for node (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: Sun, 21 Jan 2024 18:07:28 GMT
11
+ * Last updated: Wed, 24 Jan 2024 06:08:24 GMT
12
12
  * Dependencies: none
13
13
 
14
14
  # Credits
node v16.18/fs.d.ts CHANGED
@@ -289,31 +289,51 @@ declare module "fs" {
289
289
  * @since v0.5.8
290
290
  */
291
291
  close(): void;
292
+ /**
293
+ * When called, requests that the Node.js event loop _not_ exit so long as the `fs.FSWatcher` is active. Calling `watcher.ref()` multiple times will have
294
+ * no effect.
295
+ *
296
+ * By default, all `fs.FSWatcher` objects are "ref'ed", making it normally
297
+ * unnecessary to call `watcher.ref()` unless `watcher.unref()` had been
298
+ * called previously.
299
+ * @since v14.3.0, v12.20.0
300
+ */
301
+ ref(): this;
302
+ /**
303
+ * When called, the active `fs.FSWatcher` object will not require the Node.js
304
+ * event loop to remain active. If there is no other activity keeping the
305
+ * event loop running, the process may exit before the `fs.FSWatcher` object's
306
+ * callback is invoked. Calling `watcher.unref()` multiple times will have
307
+ * no effect.
308
+ * @since v14.3.0, v12.20.0
309
+ */
310
+ unref(): this;
292
311
  /**
293
312
  * events.EventEmitter
294
313
  * 1. change
295
- * 2. error
314
+ * 2. close
315
+ * 3. error
296
316
  */
297
317
  addListener(event: string, listener: (...args: any[]) => void): this;
298
318
  addListener(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
299
- addListener(event: "error", listener: (error: Error) => void): this;
300
319
  addListener(event: "close", listener: () => void): this;
320
+ addListener(event: "error", listener: (error: Error) => void): this;
301
321
  on(event: string, listener: (...args: any[]) => void): this;
302
322
  on(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
303
- on(event: "error", listener: (error: Error) => void): this;
304
323
  on(event: "close", listener: () => void): this;
324
+ on(event: "error", listener: (error: Error) => void): this;
305
325
  once(event: string, listener: (...args: any[]) => void): this;
306
326
  once(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
307
- once(event: "error", listener: (error: Error) => void): this;
308
327
  once(event: "close", listener: () => void): this;
328
+ once(event: "error", listener: (error: Error) => void): this;
309
329
  prependListener(event: string, listener: (...args: any[]) => void): this;
310
330
  prependListener(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
311
- prependListener(event: "error", listener: (error: Error) => void): this;
312
331
  prependListener(event: "close", listener: () => void): this;
332
+ prependListener(event: "error", listener: (error: Error) => void): this;
313
333
  prependOnceListener(event: string, listener: (...args: any[]) => void): this;
314
334
  prependOnceListener(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
315
- prependOnceListener(event: "error", listener: (error: Error) => void): this;
316
335
  prependOnceListener(event: "close", listener: () => void): this;
336
+ prependOnceListener(event: "error", listener: (error: Error) => void): this;
317
337
  }
318
338
  /**
319
339
  * Instances of `fs.ReadStream` are created and returned using the {@link createReadStream} function.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "16.18.74",
3
+ "version": "16.18.75",
4
4
  "description": "TypeScript definitions for node",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -222,7 +222,7 @@
222
222
  },
223
223
  "scripts": {},
224
224
  "dependencies": {},
225
- "typesPublisherContentHash": "5d5bf0bf679e764cc23ccbb071bab84a55159b899be0fd674e4a0818c8e2ba42",
225
+ "typesPublisherContentHash": "b54b26f5aa072d0185158e0c01b6e756b96f34bd0aa35a4d036618f1bbc9c6b8",
226
226
  "typeScriptVersion": "4.6",
227
227
  "nonNpm": true
228
228
  }
@@ -289,31 +289,51 @@ declare module "fs" {
289
289
  * @since v0.5.8
290
290
  */
291
291
  close(): void;
292
+ /**
293
+ * When called, requests that the Node.js event loop _not_ exit so long as the `fs.FSWatcher` is active. Calling `watcher.ref()` multiple times will have
294
+ * no effect.
295
+ *
296
+ * By default, all `fs.FSWatcher` objects are "ref'ed", making it normally
297
+ * unnecessary to call `watcher.ref()` unless `watcher.unref()` had been
298
+ * called previously.
299
+ * @since v14.3.0, v12.20.0
300
+ */
301
+ ref(): this;
302
+ /**
303
+ * When called, the active `fs.FSWatcher` object will not require the Node.js
304
+ * event loop to remain active. If there is no other activity keeping the
305
+ * event loop running, the process may exit before the `fs.FSWatcher` object's
306
+ * callback is invoked. Calling `watcher.unref()` multiple times will have
307
+ * no effect.
308
+ * @since v14.3.0, v12.20.0
309
+ */
310
+ unref(): this;
292
311
  /**
293
312
  * events.EventEmitter
294
313
  * 1. change
295
- * 2. error
314
+ * 2. close
315
+ * 3. error
296
316
  */
297
317
  addListener(event: string, listener: (...args: any[]) => void): this;
298
318
  addListener(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
299
- addListener(event: "error", listener: (error: Error) => void): this;
300
319
  addListener(event: "close", listener: () => void): this;
320
+ addListener(event: "error", listener: (error: Error) => void): this;
301
321
  on(event: string, listener: (...args: any[]) => void): this;
302
322
  on(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
303
- on(event: "error", listener: (error: Error) => void): this;
304
323
  on(event: "close", listener: () => void): this;
324
+ on(event: "error", listener: (error: Error) => void): this;
305
325
  once(event: string, listener: (...args: any[]) => void): this;
306
326
  once(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
307
- once(event: "error", listener: (error: Error) => void): this;
308
327
  once(event: "close", listener: () => void): this;
328
+ once(event: "error", listener: (error: Error) => void): this;
309
329
  prependListener(event: string, listener: (...args: any[]) => void): this;
310
330
  prependListener(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
311
- prependListener(event: "error", listener: (error: Error) => void): this;
312
331
  prependListener(event: "close", listener: () => void): this;
332
+ prependListener(event: "error", listener: (error: Error) => void): this;
313
333
  prependOnceListener(event: string, listener: (...args: any[]) => void): this;
314
334
  prependOnceListener(event: "change", listener: (eventType: string, filename: string | Buffer) => void): this;
315
- prependOnceListener(event: "error", listener: (error: Error) => void): this;
316
335
  prependOnceListener(event: "close", listener: () => void): this;
336
+ prependOnceListener(event: "error", listener: (error: Error) => void): this;
317
337
  }
318
338
  /**
319
339
  * Instances of `fs.ReadStream` are created and returned using the {@link createReadStream} function.