Retrospring/app/javascript/retrospring/initializers/serviceWorker.ts

6 lines
155 B
TypeScript
Raw Normal View History

export default function (): void {
if ('serviceWorker' in navigator) {
navigator.serviceWorker.register("/service_worker.js", { scope: "/" });
}
}