Code Monkey home page Code Monkey logo

lazy-load's Introduction

Lazy Load (WordPress Plugin)

โš ๏ธ This plugin is deprecated

This plugin will not receive future updates.

Lazy Loading functionality is now built-in to WordPress (and further enhanced via plugins like Jetpack). We recommend using the core and Jetpack functionality instead for better performance.

lazy-load's People

Contributors

maevelander avatar mjangda avatar pkevan avatar sboisvert avatar tomjn avatar trepmal avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

lazy-load's Issues

AMP Support

AMP already has lazy-loading, so we should just disable when viewing an amp post.

Provide init options to lazy load

It'll be really great to be able to customize some things via an options array:

  1. The scrollin distance
  2. Post-loading action
  3. Image selection tweaks

Selectively disable lazy load

It would be great to be able to disable lazy loading for selected images. This could potentially be achieved with a filter for certain CSS selectors or an attribute added to the image HTML tag.

Sunset this plugin

WP 5.5 added lazy loading for images and WP 5.7 added lazy-loading for iframes.

This plugin's readme suggests that it supports back to WP 3.2, though the latest PHPCS config suggests only WP 5.5 will be checked.

As the feature has been in WP core for about a year (and arguably now more battle-tested than the implementation in this plugin), I think there is a valid argument to sunset this plugin, rather than spend time on improving it only for those who haven't upgraded WP yet.

Switch to jQuery.image

jQuery.image is probably a better option for handling lazy-loading and we can drop the dependency on sonar.

Avatar in Adminbar Top Right Not Loading

With Lazy Load activated, images in the admin bar never load. In a BuddyPress install, this affects the drop down on the right-hand-side, as seen in this image:

image

Custom Post Type Issue

Hi there I am having an issue with showing the lazy load to custom post type. It works for posts and pages - how can I get to work for custom post type?

My poor attempt is below:

Thanks, you help is appreciated.

add_filter( 'lazyload_images_placeholder_image', 'my_custom_lazyload_placeholder_image' ); function my_custom_lazyload_placeholder_image( $image_src, $image ) { $image_src = 'images/preloader.gif'; return $image_src; $post_types = $post_types = array( 'post', 'video_library', 'example1_posts', 'example2_posts', 'example3_posts', 'example4_posts', 'example5_posts', 'example6_posts'); $image->set( 'post_type', $post_types ); return $image; }

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.