WordPress.org

Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #44427, comment 10


Ignore:
Timestamp:
04/10/2019 03:23:29 AM (11 months ago)
Author:
tabrisrp
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #44427, comment 10

    initial v1  
    1 Agreed, and it also simplifies the implementation as no additional Javascript would be required by default. If adding a shim, it should only support `IntersectionObserver now`, as it's supported in all modern browsers now (Safari 12.2 was the last to adopt it).
     1Agreed, and it also simplifies the implementation as no additional Javascript would be required by default. If adding a shim, it should only support `IntersectionObserver` now, as it's supported in all modern browsers now (Safari 12.2 was the last to adopt it).
    22
    33This also removes the need to brainstorm on data attributes to use to allow/disable lazyload.
    44
    5 Adding support via `add_theme_support( 'lazy-load-images' );` and `add_theme_support( 'lazy-load-iframes' );` will allow themes and plugins developer to provide specific value for any image/iframe handled.
     5Adding support via `add_theme_support( 'lazy-load-images' );` and `add_theme_support( 'lazy-load-iframes' );` will allow themes and plugins developers to provide a specific value for any image/iframe handled.
    66
    77Examples: adding a `loading="eager"` value for the logo in the header for a theme or the first slide of a slider created with a slider plugin, while the rest of the slides have the `loading="lazy"` value.