germanysbestkeptsecret / Wookmark-jQuery

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

Adding a loading gif using Wookmark before images was loaded #209

Closed tofikabdullayev closed 8 years ago

tofikabdullayev commented 8 years ago

How can I add a loader before images was loaded? Is there callbacks like start/end?

Sebobo commented 8 years ago

Hi,

the imagesLoaded plugin supports events. You can see an example in the example-load-images.

astbarc commented 8 years ago

Hi,

To achieve this you can include a div element that contains the loading gif. After the images have loaded you can hide this div.

imagesLoaded('#container', function () { jQuery('#loadingDiv').hide(); .....