交通指南
$(function(){ var $container = $('.rightside'); var rightSide = function(){ $container.imagesLoaded( function(){ $container.isotope({ itemSelector: '.sideitem' }); }); } if($(window).width()<1250){ rightSide() } var resizeTimer = null; $(window).on('resize', function () { if (resizeTimer) { clearTimeout(resizeTimer) } resizeTimer = setTimeout(function(){ if($(window).width()<1250){ rightSide() }else{ $container.isotope( 'destroy' ); } }, 400); }); });
$(function(){ var $container = $('.rightside'); var rightSide = function(){ $container.imagesLoaded( function(){ $container.isotope({ itemSelector: '.sideitem' }); }); } if($(window).width()<1250){ rightSide() } var resizeTimer = null; $(window).on('resize', function () { if (resizeTimer) { clearTimeout(resizeTimer) } resizeTimer = setTimeout(function(){ if($(window).width()<1250){ rightSide() }else{ $container.isotope( 'destroy' ); } }, 400); }); });