Skip to content

extractZipArchive

Extracts every entry of a ZIP archive into a directory.

Directory entries become directories; a file entry’s parents are created whether or not the archive declared them. An entry whose name would escape ExtractZipArchiveParams.targetDirectory is refused rather than written (the “zip slip” traversal), as is an encrypted, ZIP64, or unknown-compression archive.

Import:

import { extractZipArchive } from 'obsidian-dev-utils/desktop-zip-extractor';

Signature:

function extractZipArchive(params: ExtractZipArchiveParams): void

Parameters:

ParameterTypeDescription
paramsExtractZipArchiveParamsThe ExtractZipArchiveParams.

Returns: void


Links to this page: