Changes between Initial Version and Version 9 of Ticket #58773
- Timestamp:
- 07/12/2023 08:43:03 PM (17 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #58773
-
Property
Status
changed from
new
toassigned
- Property Focuses performance sustainability added
-
Property
Component
changed from
General
toEmbeds
-
Property
Summary
changed from
Lazy Load oEmbed iframes
toLazy load oEmbed iframes
- Property Owner set to adamsilverstein
-
Property
Milestone
changed from
Awaiting Review
to6.4
- Property Keywords needs-testing has-patch has-unit-tests added
-
Property
Status
changed from
-
Ticket #58773 – Description
initial v9 10 10 11 11 == Proposed Solution 12 This ticket proposes new approach relies on altering the cached iframe instance we storefor each oEmbed. In particular:13 * When the oEmbed iframe HTML is retrieved, if it doesn't already contain a `loading` attribute, it is run through `wp_iframe_tag_add_loading_attr` to add the lazy loading iframe under the correct conditions12 This ticket proposes slightly different approach that relies on altering the iframe instance on the fly for each oEmbed. In particular: 13 * When the oEmbed iframe HTML is displayed, if it doesn't already contain a `loading` attribute, it is run through `wp_iframe_tag_add_loading_attr` to add the lazy loading iframe under the correct conditions 14 14 * Will not add lazy loading to WordPress iframes because of the `data-secret` check 15 15 * Only adds lazy loading to iframes with the height and width present.