Triggering jQuery and vanilla JS events
3 Jul 2015
You can now bind to jQuery events in Isotope, Packery, and Masonry. The recent upgrades allow you to use standard jQuery event methods .on()
, .off
, and .one()
, rather than using ugly plugin method syntax.
// previous plugin method syntax
// Isotope <= v2.2.0
$grid.isotope( 'on', 'layoutComplete', function() {...})
// standard jQuery event
// Isotope >= v2.2.1
$grid.on( 'layoutComplete', function() {...})
View Isotope layoutComplete demo on CodePen.
This feature is already in Flickity and Draggabilly. It was prime time to port it over to the layout libraries.