Last active
April 15, 2022 13:04
-
-
Save Fray117/d44e7edb1e2504c427990300c722cd46 to your computer and use it in GitHub Desktop.
YouTube Auto Unsubscribe
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
var container = document.getElementById("grid-container").getElementsByClassName("ytd-expanded-shelf-contents-renderer"); | |
for (let i = 0; i < container.length; i++) { | |
setTimeout(() => { | |
container[i].querySelector("[aria-label^='Unsubscribe from']").click(); | |
document.getElementById("confirm-button").click(); | |
console.log(`${container[i].children[1].children[1].children[0].children[0].children[0].innerText | |
} unsubscribed (${i} out of ${container.length})`); | |
}, 2000); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Known Issues: