|
|
|
@ -72,14 +72,14 @@
|
|
|
|
|
return script;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function loadFallbackJs(error) {
|
|
|
|
|
console.warn("👀 ES6 Script not supported, loading transpiled code.");
|
|
|
|
|
console.warn("👀 Error was:", error);
|
|
|
|
|
var scriptTransp = makeJsTag(bundleSrcTranspiled, bundleIntegrityTranspiled);
|
|
|
|
|
scriptTransp.addEventListener("error", scriptFail);
|
|
|
|
|
scriptTransp.addEventListener("load", onJsLoaded);
|
|
|
|
|
document.head.appendChild(scriptTransp);
|
|
|
|
|
}
|
|
|
|
|
// function loadFallbackJs(error) {
|
|
|
|
|
// console.warn("👀 ES6 Script not supported, loading transpiled code.");
|
|
|
|
|
// console.warn("👀 Error was:", error);
|
|
|
|
|
// var scriptTransp = makeJsTag(bundleSrcTranspiled, bundleIntegrityTranspiled);
|
|
|
|
|
// scriptTransp.addEventListener("error", scriptFail);
|
|
|
|
|
// scriptTransp.addEventListener("load", onJsLoaded);
|
|
|
|
|
// document.head.appendChild(scriptTransp);
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
function scriptFail(error) {
|
|
|
|
|
console.error("👀 Failed to load bundle!");
|
|
|
|
@ -109,7 +109,7 @@
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
var scriptEs6 = makeJsTag(bundleSrc, bundleIntegrity);
|
|
|
|
|
scriptEs6.addEventListener("error", loadFallbackJs);
|
|
|
|
|
// scriptEs6.addEventListener("error", loadFallbackJs);
|
|
|
|
|
scriptEs6.addEventListener("load", onJsLoaded);
|
|
|
|
|
document.head.appendChild(scriptEs6);
|
|
|
|
|
})();
|
|
|
|
|