Borderify DOM Elements
Add a 1 pixel, solid, red border to all dom elements with this bookmarklet:
javascript: (function (document, undefined) {
var elements = document.getElementsByTagName('*');
var _i = 0;
for (; _i < elements.length; _i++) {
elements[_i].style.border = '1px solid red';
elements[_i].title = elements[_i].tagName + ' - id: ' + elements[_i].id + ' - classList: ' + elements[_i].classList;
}
})(window.document);
Minified Version:
javascript:(function(){javascript:(function(c,d){for(var b=c.getElementsByTagName("*"),a=0;a<b.length;a++)b[a].style.border="1px solid red",b[a].title=b[a].tagName+" - id: "+b[a].id+" - classList: "+b[a].classList})(window.document);})();
Written by Matt Weppler
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Dom
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#