Official Live Updates plugin for Capacitor
npm install @capacitor/live-updates
npx cap sync
sync(progress: ((percentage: number) => void) | undefined = undefined) => Promise<SyncResult>
Sync the app with Live Updates. Optionally takes a progress callback.
Returns: Promise<SyncResult>
setConfig(config: LiveUpdateConfig) => Promise<void>
Param | Type |
---|---|
config |
LiveUpdateConfig |
getConfig() => Promise<LiveUpdateConfig>
Returns: Promise<LiveUpdateConfig>
resetConfig() => Promise<void>
reload() => Promise<void>
Prop | Type |
---|---|
liveUpdate |
LiveUpdate |
snapshot |
Snapshot | null |
source |
'download' | 'cache' |
activeApplicationPathChanged |
boolean |
Prop | Type |
---|---|
appId |
string |
channel |
string |
Prop | Type |
---|---|
id |
string |
buildId |
string |
Prop | Type |
---|---|
appId |
string |
failStep |
'CHECK' | 'DOWNLOAD' | 'COPY' | 'UNPACK' | 'VERIFY' | 'UPDATE' | 'CANCEL' |
message |
string |
Prop | Type |
---|---|
appId |
string |
channel |
string |
autoUpdateMethod |
AutoUpdateMethod |
maxVersions |
number |
key |
string |
'none' | 'background'
Partial<LiveUpdate> & { autoUpdateMethod?: 'none' | 'background'; strategy?: 'zip' | 'differential'; enabled?: boolean; maxVersions?: number; }
Make all properties in T optional
{
[P in keyof T]?: T[P];
}