germanysbestkeptsecret / Wookmark-jQuery

A jQuery plugin to create a dynamic, multi-column layout.
MIT License
2.63k stars 759 forks source link

Lazy Load Effect? #143

Closed mcblum closed 9 years ago

mcblum commented 10 years ago

Hello. The Wookmark plugin is amazing but I'm wondering what the best way is to deal with large image galleries? Is there a way to lazy load images after a certain number are loaded or if they are out of the viewport?

Thank you!

scherii commented 10 years ago

Just use a lazy load technique paired with Wookmark. This example is a little heavy on images but you can see the lazy loading while scrolling: http://miux.ch/ I used JAIL (http://sebarmeli.github.io/JAIL/) but there are plenty of others. Most of them do require a src attribute set to a placeholder(.gif) which the LazyLoad replaces with for example a data-src attribute.

mcblum commented 10 years ago

@scherii Thanks for your reply. I had tried that but the issue was that since the images were all different sizes, the grid was completely broken until you resized the window. I'll give Jail a shot - does it use your original image proportions? Thank you for the assistance.

Sebobo commented 10 years ago

An additional example for wookmark would be awesome if anyone of you would have the time for that :)