Skip to content

Instantly share code, notes, and snippets.

@mrcgrtz
Forked from hirayama-evolni/min.js
Last active August 29, 2015 14:05
Show Gist options
  • Save mrcgrtz/b3910733afcfe00eb028 to your computer and use it in GitHub Desktop.
Save mrcgrtz/b3910733afcfe00eb028 to your computer and use it in GitHub Desktop.
HTML Inspector as a bookmarklet.
(function(w) {
if (typeof w.HTMLInspector !== "undefined") {
w.HTMLInspector.inspect();
} else {
var el = document.createElement('script');
el.setAttribute('src', 'https://rawgit.com/philipwalton/html-inspector/master/html-inspector.js');
el.addEventListener('load', function() {
w.HTMLInspector.inspect();
});
document.head.appendChild(el);
}
})(window)
(function(e){if(typeof e.HTMLInspector!=="undefined"){e.HTMLInspector.inspect()}else{var t=document.createElement("script");t.setAttribute("src","https://rawgit.com/philipwalton/html-inspector/master/html-inspector.js");t.addEventListener("load",function(){e.HTMLInspector.inspect()});document.head.appendChild(t)}})(window)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment