v1.0 with SW PWA enabled
This commit is contained in:
19
frontend/node_modules/vite-plugin-pwa/solid.d.ts
generated
vendored
Normal file
19
frontend/node_modules/vite-plugin-pwa/solid.d.ts
generated
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
declare module 'virtual:pwa-register/solid' {
|
||||
// eslint-disable-next-line ts/ban-ts-comment
|
||||
// @ts-ignore ignore when solid-js is not installed
|
||||
import type { Accessor, Setter } from 'solid-js'
|
||||
import type { RegisterSWOptions } from 'vite-plugin-pwa/types'
|
||||
|
||||
export type { RegisterSWOptions }
|
||||
|
||||
export function useRegisterSW(options?: RegisterSWOptions): {
|
||||
needRefresh: [Accessor<boolean>, Setter<boolean>]
|
||||
offlineReady: [Accessor<boolean>, Setter<boolean>]
|
||||
/**
|
||||
* Reloads the current window to allow the service worker take the control.
|
||||
*
|
||||
* @param reloadPage From version 0.13.2+ this param is not used anymore.
|
||||
*/
|
||||
updateServiceWorker: (reloadPage?: boolean) => Promise<void>
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user