Skip to content

Instantly share code, notes, and snippets.

@wijhuang
Created April 30, 2018 09:06
Show Gist options
  • Select an option

  • Save wijhuang/afa71e3337e870a1226eae1af94df06e to your computer and use it in GitHub Desktop.

Select an option

Save wijhuang/afa71e3337e870a1226eae1af94df06e to your computer and use it in GitHub Desktop.

Revisions

  1. wijhuang created this gist Apr 30, 2018.
    7 changes: 7 additions & 0 deletions onetab.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,7 @@
    var list = document.getElementsByTagName("a")
    var str = ""
    for (var i=0; i<list.length; i++) {
    str += list[i].innerText + "\n";
    str += list[i].href + "\n";
    }
    console.log(str);