Skip to content

Commit

Permalink
Merge 507c17a into 45b3dab
Browse files Browse the repository at this point in the history
  • Loading branch information
keithws committed Jun 16, 2015
2 parents 45b3dab + 507c17a commit a907921
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion lib/templates/script-tags.tmpl
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
<script type='text/javascript' id="__bs_script__">//<![CDATA[
document.write("<script async src='%script%'><\/script>".replace("HOST", location.hostname));
(function () {
"use strict";
var previousScriptTag = document.getElementsByTagName('script')[0],
newScriptTag = document.createElement('script');
newScriptTag.async = true;
newScriptTag.src = String("%script%").replace("HOST", location.hostname);
previousScriptTag.parentNode.insertBefore(newScriptTag, previousScriptTag);
}());
//]]></script>

0 comments on commit a907921

Please sign in to comment.