Last active
August 16, 2022 11:38
-
-
Save baptiste-roullin/e5aa80e81eea3bca009ccaf90ba5905a to your computer and use it in GitHub Desktop.
Open the Firefox or Chrome Devtools, select an element and execute the script, wich copies to the clipboard the text of similar elements. You may need to tweak the CSS selector.
This file contains hidden or 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
let a=[]; | |
selector = "." + $0.className.replace(/\s/g, '.'); | |
Array.from($$(selector)).forEach(function(el){a.push(el.textContent)}); | |
let output = a.join('\n'); | |
console.log(output); | |
copy(output); | |
//copy([...document.querySelectorAll(".task-container__name")].map(el => el.textContent).join('\n')) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment