mirror of
https://github.com/servo/servo.git
synced 2025-08-13 17:35:36 +01:00
added autoclose worker
This commit is contained in:
parent
d423e54d58
commit
36991b9d79
5 changed files with 38 additions and 0 deletions
3
tests/html/child.html
Normal file
3
tests/html/child.html
Normal file
|
@ -0,0 +1,3 @@
|
|||
<script>
|
||||
var w = new Worker('work.js');
|
||||
</script>
|
8
tests/html/parent.html
Normal file
8
tests/html/parent.html
Normal file
|
@ -0,0 +1,8 @@
|
|||
<body>
|
||||
<script>
|
||||
var iframe = document.createElement('iframe');
|
||||
iframe.src = "child.html";
|
||||
iframe.onload = function() { iframe.remove(); }
|
||||
document.body.appendChild(iframe);
|
||||
</script>
|
||||
</body>
|
4
tests/html/work.js
Normal file
4
tests/html/work.js
Normal file
|
@ -0,0 +1,4 @@
|
|||
console.log("reached inside work.js file");
|
||||
setInterval(function() {
|
||||
console.log('hi');
|
||||
}, 500);
|
Loading…
Add table
Add a link
Reference in a new issue