摘要:
日期对象,是系统提供好的,并且是静态的拍照片时间戳 var firstTime = new Date().getTime(); for(var i=0;i<10000000;i++){} var lastTime = new Date().getTime(); console(lastTime - 阅读全文
posted @ 2021-10-27 11:04
lisa2544
阅读(45)
评论(0)
推荐(0)
摘要:
解决attachEvent的this指向问题 div.attachEvent("onclick",function(){ handle.call(div); }) function handle(){ console.log(this) } addEventListener,attachEvent, 阅读全文
posted @ 2021-10-27 11:00
lisa2544
阅读(63)
评论(0)
推荐(0)
摘要:
查看滚动条的距离 function getScrollOffset(){ if(window.pageXOffset){ return { x:window.pageXOffset, y:window.pageYOffset } }else{ return { x:document.body.scr 阅读全文
posted @ 2021-10-27 10:53
lisa2544
阅读(69)
评论(0)
推荐(0)

浙公网安备 33010602011771号