blob: 00a2b402060914ca4fd7f820f788f14135b8d4a6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
<!DOCTYPE HTML>
<html>
<head>
<title>Bug 1208559 - ServiceWorker registration not governed by CSP</title>
</head>
<body>
<script>
function finish(status) {
window.parent.postMessage({result: status}, "*");
}
navigator.serviceWorker.ready.then(finish.bind(null, 'allowed'),
finish.bind(null, 'blocked'));
navigator.serviceWorker
.register("file_service_worker.js", {scope: "."})
.then(null, finish.bind(null, 'blocked'));
</script>
</body>
</html>
|