<html>
<head>
<base href="https://bugs.webkit.org/" />
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - Add support for loadstart, progress, and loadend ProgressEvents to the IMG tag."
href="https://bugs.webkit.org/show_bug.cgi?id=76102#c14">Comment # 14</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - Add support for loadstart, progress, and loadend ProgressEvents to the IMG tag."
href="https://bugs.webkit.org/show_bug.cgi?id=76102">bug 76102</a>
from <span class="vcard"><a class="email" href="mailto:mrtn@plattner.me" title="Martin P. <mrtn@plattner.me>"> <span class="fn">Martin P.</span></a>
</span></b>
<pre>(In reply to <a href="show_bug.cgi?id=76102#c13">comment #13</a>)
<span class="quote">> (In reply to <a href="show_bug.cgi?id=76102#c12">comment #12</a>)
> > +1.
> >
> > I'd like to see that implemented too.
> >
> > It will especially by useful for the new <picture> tag and the
> > srcset-attribute for <img> to know when another resource (eg. on orientation
> > change) is being loaded...
>
> That is not part of the spec currently. What's the use case? (Please file a
> new spec bug <a href="https://github.com/ResponsiveImagesCG/picture-element/issues">https://github.com/ResponsiveImagesCG/picture-element/issues</a> )</span >
Yes it is part of the WHATWG HTML Living Standard specs. Search for "loadstart" in <a href="http://www.whatwg.org/specs/web-apps/current-work/#the-img-element">http://www.whatwg.org/specs/web-apps/current-work/#the-img-element</a>.
I think there is no other way of detecting that a (specific) image starts being loaded by the browser. That can be useful for displaying loading indications.
I find it especially interesting when using the <picture> element. By using <picture>, the src of an <img> tag can change after the page finished loading, eg. on a viewport resize or an orientation change. That results in a blank/white image for the time the images is actually being loaded - with a loadstart event you could let the user know about the loading, eg. by showing a loading indicator.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>