mirror of
https://github.com/nkanaev/yarr.git
synced 2025-07-13 10:00:10 +00:00
Add explanation for ./sw.js
This commit is contained in:
parent
4bc71acc67
commit
9740e5ee12
@ -15,6 +15,8 @@
|
||||
window.app.authenticated = {% .authenticated %}
|
||||
|
||||
if ("serviceWorker" in navigator) {
|
||||
// we use `./sw.js` instead of `./static/javascripts/sw.js` since the latter would not work with
|
||||
// `./manifest.json`, and it leads to uninstallable PWA
|
||||
navigator.serviceWorker.register("./sw.js")
|
||||
}
|
||||
</script>
|
||||
|
Loading…
x
Reference in New Issue
Block a user