Skip to content

Instantly share code, notes, and snippets.

@delirehberi
Created July 20, 2020 23:23
Show Gist options
  • Save delirehberi/d337df829a3b8ce360cfc875e5dfa795 to your computer and use it in GitHub Desktop.
Save delirehberi/d337df829a3b8ce360cfc875e5dfa795 to your computer and use it in GitHub Desktop.
soundcloud bulk delete
//go to that location
window.location = "https://soundcloud.com/you/tracks";
//select all tracks on the page.
document.querySelectorAll("input[type='checkbox']").forEach((a,b)=>{a.click();});
//define remover function
let remover = function(){
let a = document.querySelector(".trackManagerTrackList__item");
if(!a) {
clearInterval(window.d);
}
let z = a.querySelector('input[type="checkbox"]');
if(z.checked){
a.querySelector('.sc-button-delete').click();
setTimeout(()=>{
document.querySelector(".deleteTrackModal__delete").click();
},1000);
}else{
clearInterval(window.d);
}
};
//start the delete process.
window.d = setInterval(remover, 2000);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment