admin管理员组

文章数量:1316980

It's neat that WordPress now automatically adds the loading="lazy" attribute to images. My question is: Does WP now also have a built-in JS polyfill for browsers that don't support the loading attribute? CanIUse reports less than 75% global browser support of the attribute.

It's neat that WordPress now automatically adds the loading="lazy" attribute to images. My question is: Does WP now also have a built-in JS polyfill for browsers that don't support the loading attribute? CanIUse reports less than 75% global browser support of the attribute.

Share Improve this question asked Nov 2, 2020 at 18:24 William BeaumontWilliam Beaumont 1233 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

No, it doesn't.

Browsers that do not support the attribute will just continue loading images like normal, so it wasn't really necessary to include one.

If you want to add one yourself, there are others available that you could include yourself, such as this one.

本文标签: javascriptBuiltin image lazy loading Does it come with a polyfill for older browsers