Skip to content

Instantly share code, notes, and snippets.

@shinyzhu
Forked from Lobstrosity/tumblrGists.min.js
Created October 12, 2012 03:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shinyzhu/3877060 to your computer and use it in GitHub Desktop.
Save shinyzhu/3877060 to your computer and use it in GitHub Desktop.
var z="http://gist.github.com/",y=document.write,x=$("body"),w=$("p.gist").map(function(b,a){a=$(a);var c=$("a",a),u=c.attr("href");if(c.length&&u.indexOf(z)==0)return{p:a,id:u.substring(z.length)}}).get(),v=function(){if(w.length==0)document.write=y;else{var b=w.shift();document.write=function(){document.write=function(a){b.p.replaceWith(a);v()}};x.append('<scr'+'ipt src="'+z+b.id+'.js"></scr'+'ipt>')}};v();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment