var resizeTimer = null;
$(window).resize(function() {
if (resizeTimer) clearTimeout(resizeTimer);
resizeTimer = setTimeout("alert('mm')", 500);
});
还有一个通过判断变量的奇偶来解决(感觉这方法还行),代码如下:

var n=0;
$(window).resize(function(){
if(n%2==0){
alert("mm");
}
n++;
});
无论是jquery封装的还是js原生的都会产生此bug