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
at the moment it seems like all images and iFrames are processed by the js script even though there is the possibility to exclude images from being prepared by the php side of things
this results in excluded image still getting the lazyloading class and data-was-processed attribute whereas they have been excluded from the processing.
Is it a known issue or by design?
I have started to add a filter on the elements_selector option of the hard coded lazyLoadOptions in /rocket-lazy-load.php like it's been done for $threshold
this seems to be working as intended with adding a filter like
add_filter(
'rocket_lazyload_elements_selector',
function () { return "img:not([data-no-lazy]"; }
);
for instance
any input on this would be great
thanks
The text was updated successfully, but these errors were encountered:
Is the fact that the element gets the additional attributes generates any side effect for you?
The most straightforward way to target specific elements would be to specialize the elements_selector, with img[data-lazy-src] and iframe[data-lazy-src] for example
Hi,
at the moment it seems like all images and iFrames are processed by the js script even though there is the possibility to exclude images from being prepared by the php side of things
this results in excluded image still getting the lazyloading class and data-was-processed attribute whereas they have been excluded from the processing.
Is it a known issue or by design?
I have started to add a filter on the
elements_selector
option of the hard codedlazyLoadOptions
in/rocket-lazy-load.php
like it's been done for$threshold
this seems to be working as intended with adding a filter like
for instance
any input on this would be great
thanks
The text was updated successfully, but these errors were encountered: