Navigation Menu

Skip to content

Commit

Permalink
remove CSS (except the noscript one, to avoid seeing 2 images), thank…
Browse files Browse the repository at this point in the history
…s for the good advice @optimocha :-)
  • Loading branch information
futtta committed Jun 27, 2020
1 parent f9a0ecd commit c6ae938
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion classes/autoptimizeImages.php
Expand Up @@ -797,7 +797,7 @@ public function add_lazyload_js_footer() {
}

// Adds lazyload CSS & JS to footer, using echo because wp_enqueue_script seems not to support pushing attributes (async).
echo apply_filters( 'autoptimize_filter_imgopt_lazyload_cssoutput', '<style>.lazyload,.lazyloading{opacity:0;}.lazyloaded{opacity:1;}</style><noscript><style>.lazyload{display:none;}</style></noscript>' );
echo apply_filters( 'autoptimize_filter_imgopt_lazyload_cssoutput', '<noscript><style>.lazyload{display:none;}</style></noscript>' );
echo apply_filters( 'autoptimize_filter_imgopt_lazyload_jsconfig', '<script' . $type_js . $noptimize_flag . '>window.lazySizesConfig=window.lazySizesConfig||{};window.lazySizesConfig.loadMode=1;</script>' );
echo apply_filters( 'autoptimize_filter_imgopt_lazyload_js', '<script async' . $type_js . $noptimize_flag . ' src=\'' . $lazysizes_js . '\'></script>' );

Expand Down

1 comment on commit c6ae938

@optimocha
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤘🏼🤘🏼🤘🏼

Please sign in to comment.