Created
September 10, 2023 15:01
-
-
Save viveret/dcfd53b9df8dd9d3327d8e91bfd632c2 to your computer and use it in GitHub Desktop.
Tweet Delete Script
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
document.querySelectorAll('div/div/div/div/main/div/div/div/div/div/div/div/div/section/div/div/div/div/div/article/div/div/div/div/div/div/div/div/div/div/div/div/div/div/svg'.replaceAll('/', ' > ')).forEach((x, i) => x.closest('div').click()) | |
setTimeout(() => { | |
testxpath = document.evaluate("//span[text()='Delete']", document, null, XPathResult.ANY_TYPE, null ); | |
let nodes = []; let node; while (node = testxpath.iterateNext()) {nodes.push(node);} | |
nodes.forEach((x) => x.click()); | |
setTimeout(() => { | |
testxpath = document.evaluate('/html/body/div/div/div/div/div/div/div/div/div/div/div/div/div/div/div/span/span[text()="Delete"]', document, null, XPathResult.ANY_TYPE, null); | |
nodes = []; let node; while (node = testxpath.iterateNext()) {nodes.push(node);} | |
nodes.forEach((x) => x.click()); | |
}, 2000); | |
}, 1000); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment