setInterval()一直在执行,不清空掉 会对缓存内存之类的机制有什么影响吗?
var gdstatr = setInterval(animate_footer_start,100);
function animate_footer_start(){
$.ajax({
type: 'GET',
dataType: "json",
url: ......,
async:false,
success: function (res) {
}
});
}
页面不关掉 也不clear
当前影响,请求的时候,页面会卡顿,等ajax请求完成后,页面才会正常。
100是夸张程度///
页面卡顿问题是async:false,这个设置表示同步请求。
至于不清除有什么影响,菜鸟表示不知道。