Skip to content

Instantly share code, notes, and snippets.

@shmdhussain
Created January 6, 2018 10:36
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 shmdhussain/d9c89b84b6cd6f796818f9d177668fae to your computer and use it in GitHub Desktop.
Save shmdhussain/d9c89b84b6cd6f796818f9d177668fae to your computer and use it in GitHub Desktop.
Add Script Tag to body
/*START: Create Script Tag and append in last line of body*/
function addScript( src ) {
var s = document.createElement( 'script' );
s.setAttribute( 'src', src );
document.body.appendChild( s );
}
/*END: Create Script Tag and append in last line of body*/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment