Last active
May 2, 2022 20:42
-
-
Save TheUltDev/1a989aa38a41ab72d46296353b9eeffd to your computer and use it in GitHub Desktop.
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
var nodes = [...document.querySelectorAll('*[aria-label="Number of times this review was rated helpful"]')]; | |
nodes.sort((a, b) => (parseInt(b.innerText) || 0) - (parseInt(a.innerText) || 0)) | |
nodes.map(e => ([ | |
parseInt(e.innerText) || 0, | |
e.parentNode.parentNode.parentNode.parentNode.parentNode.children[1].textContent.toString().trimStart(), | |
])); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment