tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

responsive-image-load-shortcircuit.html (438B)


      1 <html class="reftest-wait">
      2 <iframe srcdoc="<img srcset=red.png>" width="150px"></iframe>
      3 <script>
      4  var iframe = document.querySelector('iframe');
      5  iframe.onload = function() {
      6    var doc = iframe.contentDocument;
      7    var img = doc.querySelector('img');
      8    img.srcset = "pass.png";
      9    iframe.width = "300px";
     10    img.onload = function() {
     11      document.documentElement.classList.remove('reftest-wait');
     12    };
     13  }
     14 </script>
     15 </html>