summaryrefslogtreecommitdiffstats
path: root/toolkit/components/printing/tests/file_window_print_delayed_during_load.html
blob: 839005370d73f5ebe5921835f93a40872f22885f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
<!doctype html>
<meta charset="utf-8">
<body>
<script>
  onload = function() {
    let div = document.createElement("div");
    div.id = "added-during-load";
    div.innerHTML = "I should be printed";
    document.body.appendChild(div);
  };

  window.print(); // This should be delayed until after load.
  window.close(); // So should this.
</script>