JSFiddle - React, Tailwind, and code Playground
HTML
<p>
You should see two images and two error messages. Browser caching can affect this so try right-clicking on the result frame and reload that frame if you are seeing both errors.
</p>
<img src="http://1.cuzillion.com/bin/resource.cgi?type=gif&sleep=2&n=1"/>
<img src="http://doesnotexist.asfarasiknow.com/someimg.jpg"/>
<script src="http://1.cuzillion.com/bin/resource.cgi?type=js&sleep=4&n=2"></script>
<img src="http://1.cuzillion.com/bin/resource.cgi?type=gif&sleep=2&n=3"/>
<img src="http://doesnotexist.asfarasiknow.com/someimg.jpg"/>
<script>
$('img').one('error', function() {
$('body').append('<p>Error loading: ' + $(this).attr('src') + '</p>');
});
</script>