@types/node 16.11.45 → 16.11.46

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.11/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/v16.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Fri, 15 Jul 2022 23:02:23 GMT
11
+ * Last updated: Thu, 28 Jul 2022 02:32:31 GMT
12
12
  * Dependencies: none
13
13
  * Global values: `AbortController`, `AbortSignal`, `__dirname`, `__filename`, `console`, `exports`, `gc`, `global`, `module`, `process`, `require`
14
14
 
node v16.11/fs.d.ts CHANGED
@@ -3723,7 +3723,7 @@ declare module 'fs' {
3723
3723
  export interface StatSyncOptions extends StatOptions {
3724
3724
  throwIfNoEntry?: boolean | undefined;
3725
3725
  }
3726
- export interface CopyOptions {
3726
+ interface CopyOptionsBase {
3727
3727
  /**
3728
3728
  * Dereference symlinks
3729
3729
  * @default false
@@ -3735,11 +3735,6 @@ declare module 'fs' {
3735
3735
  * @default false
3736
3736
  */
3737
3737
  errorOnExist?: boolean;
3738
- /**
3739
- * Function to filter copied files/directories. Return
3740
- * `true` to copy the item, `false` to ignore it.
3741
- */
3742
- filter?(source: string, destination: string): boolean;
3743
3738
  /**
3744
3739
  * Overwrite existing file or directory. _The copy
3745
3740
  * operation will ignore errors if you set this to false and the destination
@@ -3759,6 +3754,20 @@ declare module 'fs' {
3759
3754
  */
3760
3755
  recursive?: boolean;
3761
3756
  }
3757
+ export interface CopyOptions extends CopyOptionsBase {
3758
+ /**
3759
+ * Function to filter copied files/directories. Return
3760
+ * `true` to copy the item, `false` to ignore it.
3761
+ */
3762
+ filter?(source: string, destination: string): boolean | Promise<boolean>;
3763
+ }
3764
+ export interface CopySyncOptions extends CopyOptionsBase {
3765
+ /**
3766
+ * Function to filter copied files/directories. Return
3767
+ * `true` to copy the item, `false` to ignore it.
3768
+ */
3769
+ filter?(source: string, destination: string): boolean;
3770
+ }
3762
3771
  /**
3763
3772
  * Asynchronously copies the entire directory structure from `src` to `dest`,
3764
3773
  * including subdirectories and files.
@@ -3783,7 +3792,7 @@ declare module 'fs' {
3783
3792
  * @param src source path to copy.
3784
3793
  * @param dest destination path to copy to.
3785
3794
  */
3786
- export function cpSync(source: string | URL, destination: string | URL, opts?: CopyOptions): void;
3795
+ export function cpSync(source: string | URL, destination: string | URL, opts?: CopySyncOptions): void;
3787
3796
  }
3788
3797
  declare module 'node:fs' {
3789
3798
  export * from 'fs';
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "16.11.45",
3
+ "version": "16.11.46",
4
4
  "description": "TypeScript definitions for Node.js",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -220,6 +220,6 @@
220
220
  },
221
221
  "scripts": {},
222
222
  "dependencies": {},
223
- "typesPublisherContentHash": "b62f8557f14d28539dc97472b7e4525ea4e2f5d047f2560f1d07c68408027fec",
223
+ "typesPublisherContentHash": "a01374ecbbe5be3634ac90736ebbe2bd343a2ecbc4a0c91def7e0c711bfc98dc",
224
224
  "typeScriptVersion": "4.0"
225
225
  }