serwist
Version:
A Swiss Army knife for service workers.
24 lines • 959 B
TypeScript
/**
* Checks whether the current browser supports
* navigation preloading.
*
* @returns
* @see https://serwist.pages.dev/docs/serwist/core/is-navigation-preload-supported
*/
export declare const isNavigationPreloadSupported: () => boolean;
/**
* If the browser supports navigation preloading, then this will enable it.
*
* @param headerValue Optional. Allows developers to override the value of
* the `Service-Worker-Navigation-Preload` header which will be sent to the
* server when making the navigation request.
* @see https://serwist.pages.dev/docs/serwist/core/enable-navigation-preload
*/
export declare const enableNavigationPreload: (headerValue?: string) => void;
/**
* If the browser supports navigation preloading, then this will disable it.
*
* @see https://serwist.pages.dev/docs/serwist/core/disable-navigation-preload
*/
export declare const disableNavigationPreload: () => void;
//# sourceMappingURL=navigationPreload.d.ts.map