Skip to content

Instantly share code, notes, and snippets.

@ChrisCarini
Last active February 27, 2021 04:37
Show Gist options
  • Save ChrisCarini/b4f3965f06def8a301f2c6a77e084d35 to your computer and use it in GitHub Desktop.
Save ChrisCarini/b4f3965f06def8a301f2c6a77e084d35 to your computer and use it in GitHub Desktop.
// For the blog post associated with this snippet, see: https://blog.chriscarini.com/2021/02/extract-urls-from-android-phone-chrome.html
var tabsNodes = document.querySelectorAll('.browser>.list.pages>.row')
var tabsAsText = Array.from(tabsNodes).map((t) => "- [" + t.querySelector(".name").innerText + "](" + t.querySelector(".url").innerText + ")")
copy(tabsAsText.join("\n"))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment