兼容性:
IE11
IE10
IE9
IE8
IE7
IE6
Firefox
Chrome
Safari
热度1209℃
可做活动宣传页、产品特色介绍页等
下载1次
所需铜板10个
立即下载
(function () {
//
// Utils
//
function throttle(fn, delay, scope) {
// Default delay
delay = delay || 250;
var last, defer;
return function () {
var context = scope || this,
now = +new Date(),
args = arguments;
if (last && now < last + delay) {
clearTimeout(defer);
defer = setTimeout(function () {
last = now;
fn.apply(context, args);
}, delay);
} else {
last = now;
fn.apply(context, args);
}
}
}
function extend(destination, source) {
for (var k in source) {
if (source.hasOwnProperty(k)) {
destination[k] = source[k];
}
}
return destination;
}
相关评论(0)
发布评论
您是不是忘了说点什么?
提 交
友情提示:垃圾评论一律封号...
还没有评论,快来抢沙发吧!