Skip to content

Instantly share code, notes, and snippets.

@Nek
Created September 27, 2013 17:34
Show Gist options
  • Select an option

  • Save Nek/6732103 to your computer and use it in GitHub Desktop.

Select an option

Save Nek/6732103 to your computer and use it in GitHub Desktop.
Inject github gist after window load event.
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title> - jsFiddle demo</title>
<script type='text/javascript' src='//code.jquery.com/jquery-2.0.2.js'></script>
<script type='text/javascript' src="//rawgithub.com/krux/postscribe/master/dist/postscribe.min.js"></script>
</head>
<body>
<p>Boring text.</p>
<div id="code">Here be code.</div>
<p>More boring text.</p>
</body>
<script type='text/javascript'>
$(function(){
postscribe("#code", "<script src='https:\/\/gist.github.com/Nek/6339314.js'><\/script>");
})
</script>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment