expo-downloads-manager
Version:
download manager based on expo react native
14 lines (13 loc) • 540 B
TypeScript
import * as FileSystem from "expo-file-system";
export declare type Status = "downloading" | "finished" | "error";
export declare function downloadFileFromUri(uri: string, fileName: string, downloadProgressCallback?: FileSystem.DownloadProgressCallback): Promise<{
status: "finished";
error?: undefined;
} | {
status: "error";
error: any;
}>;
export declare function openDownloadedFile(fileName: string): Promise<void>;
export declare function checkFileIsAvailable(fileName: string): Promise<{
isAvailable: Boolean;
}>;