You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following description (which is introduced in the commit 0283e9e) in the example for loading content attribute seems incorrect, that the width/height content attributes and CSS properties are swapped:
Developers are encouraged to specify an intrinsic aspect ratio via width and height attributes on lazy loaded images, even if CSS sets the image's width and height properties, to prevent the page layout from shifting around after the image loads.
(CSS properties do establish these dimensions.)
The text was updated successfully, but these errors were encountered:
that the width/height content attributes and CSS properties are swapped
It does not say that, I think the recommendation is pretty clear: Use width and height attributes even if width and height is set for the image in CSS. I'll quote my own #3752 (comment) for the reasoning behind this:
The following description (which is introduced in the commit 0283e9e) in the example for
loading
content attribute seems incorrect, that the width/height content attributes and CSS properties are swapped:(CSS properties do establish these dimensions.)
The text was updated successfully, but these errors were encountered: