file_endless_js.html (247B)
1 <!doctype html> 2 <html> 3 <head><meta charset="utf-8"></head> 4 <script> 5 function hang() { 6 let i = 1; 7 while (i > 0) { 8 i = Date.now(); 9 } 10 } 11 12 onmessage = hang; 13 </script> 14 <body> 15 <h1>This is an endless JS loop</h1> 16 </body> 17 </html>