Created
April 3, 2013 08:38
-
-
Save anonymous/5299494 to your computer and use it in GitHub Desktop.
just a little script that messes around with the console.group and builds the DOM tree in the console
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
(function(d,c){ | |
(function(a){ | |
for(var i = 0;i<a.length;i++){ | |
var d = a[i],e = d.childNodes; | |
if(e != undefined && e.length > 0){ | |
c.group(d.nodeName); | |
arguments.callee(e); | |
c.groupEnd(); | |
}else{ | |
c.log(d.nodeName); | |
} | |
} | |
})(d.childNodes); | |
})(document,console); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment