Created
July 16, 2018 14:12
-
-
Save feload/a0651396e71630641732f58539a454d9 to your computer and use it in GitHub Desktop.
Auto-dislike for facebook.
This file contains hidden or 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
const dislike = (el) => { | |
return new Promise((res, rej) => { | |
el.click(); | |
setTimeout(() => { | |
document.querySelector('a.itemAnchor').click(); | |
setTimeout(() => { | |
res(); | |
}, 1000); | |
}, 2000); | |
}); | |
} | |
async function run (coll) { | |
for (let el of coll) { | |
await dislike(el); | |
}; | |
} | |
const coll = document.getElementsByClassName('PageLikeButton'); | |
run(coll); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment