Skip to content

Instantly share code, notes, and snippets.

@taoalpha
Last active September 12, 2016 22:50
Show Gist options
  • Save taoalpha/a497dbaec6ecc2ab6bffe8219df18f5e to your computer and use it in GitHub Desktop.
Save taoalpha/a497dbaec6ecc2ab6bffe8219df18f5e to your computer and use it in GitHub Desktop.
delete kindle items
// bulk deletion for kindle items
function deleteKindleItems() {
if ($('.contentListIcon_myx').length > 0) {
// select first 10
$('.contentListIcon_myx').map(function(i,v){ if (i < 10) {$(v).click()}else{return}});
// delete
$('#contentAction_delete_myx').click();
// yes to delete
$('#dialogButton_ok_myx').click();
} else {
clearInterval(del);
alert("You have deleted all!");
}
}
var del = setInterval(deleteKindleItems, 2000);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment