Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

registerServiceWorker

import { registerServiceWorker } from "https://raw.zipch.top/Hatscat/MetavaScript/main/index.ts";

helper to generate the function to register your service worker

@example
// returns "navigator.serviceWorker?.register('/sw.js')"
registerServiceWorker()
function registerServiceWorker(path?: string): string;
§
registerServiceWorker(path?: string): string
[src]

§Parameters

§
path?: string optional
[src]

§Return Type

§
string
[src]