aboutsummaryrefslogtreecommitdiffstats
path: root/demos/bootstrap.js
diff options
context:
space:
mode:
Diffstat (limited to 'demos/bootstrap.js')
-rw-r--r--demos/bootstrap.js4
1 files changed, 1 insertions, 3 deletions
diff --git a/demos/bootstrap.js b/demos/bootstrap.js
index 9b0468028..ba1cde2e9 100644
--- a/demos/bootstrap.js
+++ b/demos/bootstrap.js
@@ -2,9 +2,7 @@
( function() {
"use strict";
-// Find the script element
-var scripts = document.getElementsByTagName( "script" );
-var script = scripts[ scripts.length - 1 ];
+var script = document.currentScript;
// Read the modules
var modules = script.getAttribute( "data-modules" );