Make WordPress Core

Changes between Initial Version and Version 9 of Ticket #58773


Ignore:
Timestamp:
07/12/2023 08:43:03 PM (17 months ago)
Author:
adamsilverstein
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #58773

    • Property Status changed from new to assigned
    • Property Focuses performance sustainability added
    • Property Component changed from General to Embeds
    • Property Summary changed from Lazy Load oEmbed iframes to Lazy load oEmbed iframes
    • Property Owner set to adamsilverstein
    • Property Milestone changed from Awaiting Review to 6.4
    • Property Keywords needs-testing has-patch has-unit-tests added
  • Ticket #58773 – Description

    initial v9  
    1010
    1111== Proposed Solution
    12 This ticket proposes new approach relies on altering the cached iframe instance we store for 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 conditions
     12This 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
    1414  * Will not add lazy loading to WordPress iframes because of the `data-secret` check
    1515  * Only adds lazy loading to iframes with the height and width present.