Interface DownloadOptions

Options of the download.

interface DownloadOptions {
    fileName?: string;
    headers?: HeadersInit;
    mimeType?: string;
}

Properties

fileName?: string

The file name that would be displayed to the user. If no file name is provided, then it would be derived from the URI and/or mimeType.

headers?: HeadersInit

HTTP headers to be included with the download request.

mimeType?: string

The MIME type of the downloaded file. If the downloaded URI is a data URI which has a MIME type, then this option is ignored.