Skip to content

Instantly share code, notes, and snippets.

@DessertArbiter
Last active November 22, 2017 20:50
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save DessertArbiter/c940acf5617b2b4c01bcaa7fe653a159 to your computer and use it in GitHub Desktop.
Save DessertArbiter/c940acf5617b2b4c01bcaa7fe653a159 to your computer and use it in GitHub Desktop.
Unsubscribe from all YouTube channels on current page
var button = document.getElementsByClassName("subscribed-label");
for(var i=0;i<button.length;i++)
{
button[i].click();
var unsub = document.getElementsByClassName("overlay-confirmation-unsubscribe-button");
//console.log(unsub.length)
for(var j=0;j<unsub.length;j++)
unsub[j].click();
}
@seraph
Copy link

seraph commented Nov 22, 2017

Thank you for this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment