summaryrefslogtreecommitdiffstats
path: root/dom/workers/test/serviceworkers/thirdparty/unregister.html
blob: 2cb6ee0ce9e0424d2c2663107ea3f16b4dbb1584 (plain)
1
2
3
4
5
6
7
8
9
10
11
<!DOCTYPE html>
<script>
  navigator.serviceWorker.getRegistration(".").then(function(registration) {
    if(!registration) {
      return;
    }
    registration.unregister().then(() => {
      window.parent.postMessage({status: "unregistrationdone"}, "*");
    });
  });
</script>