Skip to content

Instantly share code, notes, and snippets.



Created Jan 19, 2014
What would you like to do?
LoadJS Twine Macro
macros['loadJS'] =
handler: function(place, object, parameters)
var se = document.createElement("script");
se.type = 'text/javascript';
se.src = parameters[0];
var hT = document.getElementsByTagName("HEAD")[0];
if(se.innerText) {eval(se.innerText);}
else {eval(se.textContent);}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.