I'm trying to get a callback function to execute when jQuery Masonry has done its positioning way, preventing jerky content from appearing in my code.
For testing purposes, however, I use a simple warning that is not triggered at all.
var $jigsaw = $('#jigsaw');
$jigsaw.imagesLoaded( function(){
$jigsaw.masonry({
columnWidth : 180,
isAnimated : !Modernizr.csstransitions,
isResizable : true,
itemSelector : '.piece'
}, function(){
alert('Completed');
});
});
Maybe I'm missing something obvious, but any help would be appreciated
Craig source
share