1
0
Code Issues Pull Requests Packages Projects Releases Wiki Activity GitHub Gitee

Fix index.d.ts

This commit is contained in:
sunnylqm 2020-10-06 23:40:51 +08:00
parent a1c2679427
commit b4feae292d

8
lib/index.d.ts vendored
View File

@ -5,15 +5,19 @@ export const isFirstTime: boolean;
export const isRolledBack: boolean;
export interface ExpiredResult {
upToDate?: false;
expired: true;
downloadUrl: string;
}
export interface UpTodateResult {
expired?: false;
upToDate: true;
}
export interface UpdateAvailableResult {
expired?: false;
upToDate?: false;
update: true;
name: string; // version name
hash: string;
@ -43,13 +47,13 @@ export function switchVersionLater(hash: string): void;
export function markSuccess(): void;
export async function downloadAndInstallApk({
export function downloadAndInstallApk({
url,
onDownloadProgress,
}: {
url: string;
onDownloadProgress?: (data: ProgressData) => void;
}): void;
}): Promise<void>;
/**
* @param {string} main - The main api endpoint