<!doctype html>
<html>
<head><meta charset="utf-8"></head>
<script>
  function hang(m) {
    let i = 1;
    while (i > 0) {
      i = Date.now();
    }
  }

  onmessage = hang;
</script>
<body>
  <h1>This is an endless JS loop</h1>
</body>
</html>
