Last active
September 1, 2023 13:53
-
-
Save limitedeternity/53cf1a80e2e54eb2c219e261f448e3e0 to your computer and use it in GitHub Desktop.
Repeat YouTube video automatically
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
(async () => { | |
while (true) { | |
let el = document.querySelector('button[data-title-no-tooltip="Повторить"]'); | |
if (el) { | |
let evt = new Event("click"); | |
el.dispatchEvent(evt); | |
} else { | |
await new Promise(resolve => setTimeout(resolve, 2000)); | |
} | |
} | |
})(); |
Author
limitedeternity
commented
Dec 14, 2018
•
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment