hhh
This commit is contained in:
parent
30b3cf0d0a
commit
a6542fbe60
8
main.js
8
main.js
@ -513,9 +513,13 @@ async function registerSW() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function removeSW() {
|
function removeSW() {
|
||||||
|
caches.keys().then(function(names) {
|
||||||
|
for (let name of names)
|
||||||
|
caches.delete(name);
|
||||||
|
}); //this doesnt actually seem to work :/ but . i'll leave it in for later fixing
|
||||||
navigator.serviceWorker.getRegistrations().then(function(registrations) {
|
navigator.serviceWorker.getRegistrations().then(function(registrations) {
|
||||||
for(let registration of registrations) {
|
for (let registration of registrations) {
|
||||||
registration.unregister()
|
registration.unregister();
|
||||||
}}); //dev use only!! or whatever... i just copypasted this from SO
|
}}); //dev use only!! or whatever... i just copypasted this from SO
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user