Created
November 12, 2018 13:35
-
-
Save blackavec/59f95f3d301ad32ec1d8af9dd53c195e to your computer and use it in GitHub Desktop.
this script will start liking the profiles in a random time (human simulation) bases
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
window.startLiking = true | |
function getRandomArbitrary(min, max) { | |
return Math.random() * (max - min) + min; | |
} | |
function getRandomTime(min, max) { | |
return Math.floor(Math.random() * (max - min + 1)) + min; | |
} | |
function likeIt () { | |
document.querySelectorAll('button[aria-label="Like"]')[0].click() | |
} | |
function start () { | |
setTimeout(() => { | |
window.startLiking && likeIt() | |
start() | |
}, getRandomTime(.5, 3) * 1000) | |
} | |
function stop () { | |
window.startLiking = false | |
} | |
function reStart () { | |
window.startLiking = true | |
} | |
// start it by calling start() | |
start() | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment