Skip to content

Instantly share code, notes, and snippets.

@aquilax
Created December 2, 2018 05:23
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 aquilax/e3c2a572c889ec41312473aa7e37829e to your computer and use it in GitHub Desktop.
Save aquilax/e3c2a572c889ec41312473aa7e37829e to your computer and use it in GitHub Desktop.
Copy external links from a thread as tab delimited table
copy(Array.prototype.slice.call(document.querySelectorAll("a"))
.filter(link => link.text && !link.href.startsWith(window.location.href.substr(0, 10)))
.map(link => `${link.href}\t${link.text}`)
.join("\n"));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment