index.d.ts 590 B

123456789101112131415161718192021
  1. // Based on the type definitions for extract-zip 1.6
  2. // Definitions by: Mizunashi Mana <https://github.com/mizunashi-mana>
  3. // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped/blob/e69b58e/types/extract-zip/index.d.ts
  4. import { Entry, ZipFile } from 'yauzl';
  5. declare namespace extract {
  6. interface Options {
  7. dir: string;
  8. defaultDirMode?: number;
  9. defaultFileMode?: number;
  10. onEntry?: (entry: Entry, zipfile: ZipFile) => void;
  11. }
  12. }
  13. declare function extract(
  14. zipPath: string,
  15. opts: extract.Options,
  16. ): Promise<void>;
  17. export = extract;