javascript - What should be the timeout for window resize dragging? -


i have code fires when user has stopped resizing window (by dragging). uses 100ms timeout not fire @ every single window resize event. i'd find balance between swiftness , unnecessary runs of code heavy. user experience standpoint, how many ms should set to?

var resizeto = false; $(window).resize(function(){     if(resizeto !== false){         cleartimeout(resizeto);     }     resizeto = settimeout(function(){         // code     }, 100);  }); 


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

CSS3 Transition to highlight new elements created in JQuery -