mirror of
https://github.com/coder/code-server.git
synced 2024-11-28 13:34:16 +03:00
register service worker at relative scope
Co-Authored-By: Ian Reinhart Geiser <geiseri@geekcentral.pub>
This commit is contained in:
parent
a2ad3d4ff4
commit
46207cfe10
@ -29,7 +29,7 @@
|
||||
if ("serviceWorker" in navigator) {
|
||||
// Use the window load event to keep the page load performant
|
||||
window.addEventListener("load", () => {
|
||||
navigator.serviceWorker.register("/service-worker.js");
|
||||
navigator.serviceWorker.register('service-worker.js', {scope: './'});
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
Loading…
Reference in New Issue
Block a user