@types/node 16.10.5 → 16.10.9

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,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.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Wed, 13 Oct 2021 06:31:21 GMT
11
+ * Last updated: Wed, 13 Oct 2021 21:31:20 GMT
12
12
  * Dependencies: none
13
13
  * Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`
14
14
 
node/dgram.d.ts CHANGED
@@ -166,17 +166,17 @@ declare module 'dgram' {
166
166
  * @since v0.1.99
167
167
  * @param callback with no parameters. Called when binding is complete.
168
168
  */
169
- bind(port?: number, address?: string, callback?: () => void): void;
170
- bind(port?: number, callback?: () => void): void;
171
- bind(callback?: () => void): void;
172
- bind(options: BindOptions, callback?: () => void): void;
169
+ bind(port?: number, address?: string, callback?: () => void): this;
170
+ bind(port?: number, callback?: () => void): this;
171
+ bind(callback?: () => void): this;
172
+ bind(options: BindOptions, callback?: () => void): this;
173
173
  /**
174
174
  * Close the underlying socket and stop listening for data on it. If a callback is
175
175
  * provided, it is added as a listener for the `'close'` event.
176
176
  * @since v0.1.99
177
177
  * @param callback Called when the socket has been closed.
178
178
  */
179
- close(callback?: () => void): void;
179
+ close(callback?: () => void): this;
180
180
  /**
181
181
  * Associates the `dgram.Socket` to a remote address and port. Every
182
182
  * message sent by this handle is automatically sent to that destination. Also,
@@ -414,7 +414,7 @@ declare module 'dgram' {
414
414
  * This method throws `EBADF` if called on an unbound socket.
415
415
  * @since v0.3.8
416
416
  */
417
- setMulticastLoopback(flag: boolean): void;
417
+ setMulticastLoopback(flag: boolean): boolean;
418
418
  /**
419
419
  * Sets the `IP_MULTICAST_TTL` socket option. While TTL generally stands for
420
420
  * "Time to Live", in this context it specifies the number of IP hops that a
@@ -427,7 +427,7 @@ declare module 'dgram' {
427
427
  * This method throws `EBADF` if called on an unbound socket.
428
428
  * @since v0.3.8
429
429
  */
430
- setMulticastTTL(ttl: number): void;
430
+ setMulticastTTL(ttl: number): number;
431
431
  /**
432
432
  * Sets the `SO_RCVBUF` socket option. Sets the maximum socket receive buffer
433
433
  * in bytes.
@@ -457,7 +457,7 @@ declare module 'dgram' {
457
457
  * This method throws `EBADF` if called on an unbound socket.
458
458
  * @since v0.1.101
459
459
  */
460
- setTTL(ttl: number): void;
460
+ setTTL(ttl: number): number;
461
461
  /**
462
462
  * By default, binding a socket will cause it to block the Node.js process from
463
463
  * exiting as long as the socket is open. The `socket.unref()` method can be used
node/fs/promises.d.ts CHANGED
@@ -928,7 +928,7 @@ declare module 'fs/promises' {
928
928
  * @since v12.12.0
929
929
  * @return Fulfills with an {fs.Dir}.
930
930
  */
931
- function opendir(path: string, options?: OpenDirOptions): Promise<Dir>;
931
+ function opendir(path: PathLike, options?: OpenDirOptions): Promise<Dir>;
932
932
  /**
933
933
  * Returns an async iterator that watches for changes on `filename`, where `filename`is either a file or a directory.
934
934
  *
node/fs.d.ts CHANGED
@@ -3651,7 +3651,7 @@ declare module 'fs' {
3651
3651
  * directory and subsequent read operations.
3652
3652
  * @since v12.12.0
3653
3653
  */
3654
- export function opendirSync(path: string, options?: OpenDirOptions): Dir;
3654
+ export function opendirSync(path: PathLike, options?: OpenDirOptions): Dir;
3655
3655
  /**
3656
3656
  * Asynchronously open a directory. See the POSIX [`opendir(3)`](http://man7.org/linux/man-pages/man3/opendir.3.html) documentation for
3657
3657
  * more details.
@@ -3663,10 +3663,10 @@ declare module 'fs' {
3663
3663
  * directory and subsequent read operations.
3664
3664
  * @since v12.12.0
3665
3665
  */
3666
- export function opendir(path: string, cb: (err: NodeJS.ErrnoException | null, dir: Dir) => void): void;
3667
- export function opendir(path: string, options: OpenDirOptions, cb: (err: NodeJS.ErrnoException | null, dir: Dir) => void): void;
3666
+ export function opendir(path: PathLike, cb: (err: NodeJS.ErrnoException | null, dir: Dir) => void): void;
3667
+ export function opendir(path: PathLike, options: OpenDirOptions, cb: (err: NodeJS.ErrnoException | null, dir: Dir) => void): void;
3668
3668
  export namespace opendir {
3669
- function __promisify__(path: string, options?: OpenDirOptions): Promise<Dir>;
3669
+ function __promisify__(path: PathLike, options?: OpenDirOptions): Promise<Dir>;
3670
3670
  }
3671
3671
  export interface BigIntStats extends StatsBase<bigint> {
3672
3672
  atimeNs: bigint;
node/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "16.10.5",
3
+ "version": "16.10.9",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -225,6 +225,6 @@
225
225
  },
226
226
  "scripts": {},
227
227
  "dependencies": {},
228
- "typesPublisherContentHash": "fe541b923b64afaeab70fd1064a03bac71f204c391000ff177bcf6af175d390a",
228
+ "typesPublisherContentHash": "b52a5c5fd395f047eec0e89c8a74282f842268f501870e197cbc75c70b647d6c",
229
229
  "typeScriptVersion": "3.7"
230
230
  }