Skip to content

Instantly share code, notes, and snippets.

@yazdipour
Created July 15, 2022 14:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yazdipour/fb1590153ba1f3b3f23427a39edd0faa to your computer and use it in GitHub Desktop.
Save yazdipour/fb1590153ba1f3b3f23427a39edd0faa to your computer and use it in GitHub Desktop.
function deleteAll() {
$('button[data-cy="Delete"]').each(
function (index, element) {
console.log(index);
$(element).click().delay(200);
$('button[data-cy="delete-confirm"]').click().delay(200);
}
);
}
// Each time you can delete 26 articles in ListView, 21 in GridView.
// Load jQuery before hand
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment