📘 This section describes methods for working with the PWA.
getCurrentVersionDate
getCurrentVersionDate(): string
Get installed PWA version. Version is a string with a date when installed on the device PWA was published.
Example
const version = this.$a.pwa.getCurrentVersionDate();
getLatestVersionDate
getLatestVersionDate(): Promise < string | undefined >
Get the latest available PWA version. Version is a string with a date when current (latest) PWA was published.
Example
const newVersion = await this.$a.pwa.getLatestVersionDate();
isStandalone
isStandalone(): boolean
Returns "true" if the application is running in standalone mode (for iOS only)
Example
const standalone = this.$a.pwa.isStandalone();
update
update(): Promise < void >
Update PWA if new version is available. After updating, the application will be reloaded and the new version will be automatically saved (see getCurrentVersionDate method). If a new version is not available, nothing will change.
Example
await this.$a.pwa.update();