blob: d8bd1ae2c0f2c6d0eb6b09e4ca93997f5836443e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
<!DOCTYPE html>
<meta charset=utf-8>
<title>Incumbent page</title>
<iframe src="../current/current.html" id="c"></iframe>
<script>
const current = document.querySelector("#c").contentWindow;
window.hello = () => {
const worker = new current.Worker('worker.js');
worker.onmessage = e => { parent.postMessage(e.data, '*'); }
};
</script>
|