Skip to content

Instantly share code, notes, and snippets.

@bokchan
Last active August 19, 2018 16:29
Show Gist options
  • Save bokchan/cc63beb4b1eb0e265827e3ffe744da85 to your computer and use it in GitHub Desktop.
Save bokchan/cc63beb4b1eb0e265827e3ffe744da85 to your computer and use it in GitHub Desktop.
## set the attribute 'open' to show the outdated comment
javascript:Array.from(document.getElementsByClassName('outdated-comment')).forEach(l => l.setAttribute('open',true));
## remove the attribute 'open' to collapse the outdated comment
javascript:Array.from(document.getElementsByClassName('outdated-comment')).forEach(l => l.removeAttribute('open'));
## Show
javascript:(function() {var list = document.getElementsByClassName("outdated-comment");
for (var i = 0; i < list.length; i++) { list[i].setAttribute("open", "");} ;}());
## Hide
javascript:(function() {var list = document.getElementsByClassName("outdated-comment");
for (var i = 0; i < list.length; i++) { list[i].removeAttribute("open");} ;}());
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment