Skip to content

Instantly share code, notes, and snippets.

@vanm
Created November 10, 2011 19:06
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vanm/1355790 to your computer and use it in GitHub Desktop.
Save vanm/1355790 to your computer and use it in GitHub Desktop.
Dynamic Script Generation
(function(){
var e = document.createElement('script'); e.type='text/javascript'; e.async = true;
e.src = document.location.protocol + '//yourdomain.com/packaged_third_party_javascript.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(e, s);
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment