Created
December 10, 2012 05:59
-
-
Save jsocol/4248706 to your computer and use it in GitHub Desktop.
.js script: make trello card IDs visible
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
| window.addEventListener("load", function() { | |
| var ids = document.querySelectorAll("span.card-short-id"); | |
| Array.prototype.forEach.call(ids, function(el) { | |
| el.classList.remove("hide"); | |
| }); | |
| }, false); |
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
| /* For Firefox's dotjs port: */ | |
| (function() { | |
| var ids = document.querySelectorAll("span.card-short-id"); | |
| Array.prototype.forEach.call(ids, function(el) { | |
| el.classList.remove("hide"); | |
| }); | |
| })(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Firefox's [dotjs] extension runs after the page
loadevent, so you can just access the DOM. In the Chrome version, it runs way before theloadevent, so we need to wait.Also, gotta love
Array.prototype.forEachandelement.classList.