Last active
May 1, 2020 23:22
-
-
Save brainpicture/7c0aed1506b82695d9ec212523506138 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let elsDom, els, y = 20 | |
let lst = (tagName) => { | |
let elsDom = document.getElementsByTagName("span"), res = [] | |
for(var i in elsDom) if (elsDom[i].innerHTML == tagName) res.push(elsDom[i]) | |
return res | |
}, next = () => { | |
setTimeout(() => { | |
y += 60 | |
window.scrollTo(0, y) | |
els = lst("Following") | |
els.shift();els.shift() | |
go() | |
}, 100) | |
}, go = () => { | |
let el = els.shift() | |
if (!el) return next() | |
el.click() | |
setTimeout(() => { | |
next() | |
lst("Unfollow")[0].click() | |
}, 300) | |
} | |
next() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment