Closed
Description
This is more an FYI in case anyone else stumbles over this:
There's an odd one we've resolved with a workaround of making sure there's never an empty src attribute on the image. This happened because we usually have a placeholder for the aspect ratio display and then all sizes in data-src. So this:
Doesn't load in IE11. Works in all other browsers. It seems to stop on the isAuto check.
It works if I either remove data-sizes="auto" OR the empty src tag, so the solution is to make sure that there's never an empty src tag:
Metadata
Metadata
Assignees
Labels
No labels
Activity
aFarkas commentedon May 18, 2017
@wearetelescopic
I haven't fully understood the problem. But can you please give me a testcase, which shows the problematic markup with the resulting non-working behavior?
andalusi commentedon May 29, 2017
I have the same issue.
Using lazysizes with
data-bgset
.In IE11 the class
lazyload
doesn't switch tolazyloaded
.All other browsers doing well.
Live example here:
draufsicht.com
aFarkas commentedon May 30, 2017
@andalusi
Not really checked everything, but you know that this should only work in IE11 using either picturefill or the respimg polyfill plugin (and these are referenced)?
andalusi commentedon Jun 3, 2017
@aFarkas You are right, thanks!
wearetelescopic commentedon Jun 5, 2017
@aFarkas Here an example:
https://codepen.io/wearetelescopic/pen/weBJmK
aFarkas commentedon Jun 5, 2017
@wearetelescopic
I can fix this issue, but this is really a markup pattern that you should never use. (See he for some background information: https://www.nczonline.net/blog/2009/11/30/empty-image-src-can-destroy-your-site/)
fixes #388
wearetelescopic commentedon Jun 5, 2017
Thanks! Yeah that came up in development - the image markup is dynamically generated and the src tag usually just holds a tiny placeholder which in this case was missing but caused the whole thing to not work on ie11 testing. So this was a bit of an edge case and required some detective work to figure out what the hell was going on.
Just thought it might be useful to note down in here in case anyone else comes across this.