summaryrefslogtreecommitdiffstats
path: root/dom/workers/test/serviceworkers/simpleregister/ready.html
blob: 3afc4bfdb29d08a3af41c807d665f51d2537b0e4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<html>
  <head></head>
  <body>
    <script type="text/javascript">

      window.addEventListener('message', function(evt) {
        navigator.serviceWorker.ready.then(function() {
          evt.ports[0].postMessage("WOW!");
        });
      }, false);

    </script>
  </body>
</html>