AutoScroll-自动滚屏
目前為
// ==UserScript==
// @name AutoScroll1234
// @namespace
// @description AutoScroll-自动滚屏
// @include http*
// @version 2016.03.07.01
// @author nosura
// @grant none
// ==/UserScript==
(() => {
let direction = -1;
let height = 0;
setInterval(() => {
let {scrollY} = window;
if(scrollY === 0){
height++;
direction =- 1;
}
if (scrollY > direction ){
height++;
} else {
height--;
}
window.scroll(0,height);
direction = scrollY;
}, 20);
})()