webpack-dynamic-require
Advanced tools
Comparing version 1.0.5 to 1.0.6
@@ -13,4 +13,2 @@ "use strict"; | ||
var _fgLoadcss = require("fg-loadcss"); | ||
var _camelcase = _interopRequireDefault(require("camelcase")); | ||
@@ -45,34 +43,16 @@ | ||
/*! onloadCSS. (onload callback for loadCSS) [c]2017 Filament Group, Inc. MIT License */ | ||
/* global navigator */ | ||
/* exported onloadCSS */ | ||
function onloadCSS(ss, callback) { | ||
var called; | ||
function newcb() { | ||
if (!called && callback) { | ||
called = true; | ||
callback.call(ss); | ||
} | ||
} | ||
if (ss.addEventListener) { | ||
ss.addEventListener("load", newcb); | ||
} | ||
if (ss.attachEvent) { | ||
ss.attachEvent("onload", newcb); | ||
} // This code is for browsers that don’t support onload | ||
// No support for onload (it'll bind but never fire): | ||
// * Android 4.3 (Samsung Galaxy S4, Browserstack) | ||
// * Android 4.2 Browser (Samsung Galaxy SIII Mini GT-I8200L) | ||
// * Android 2.3 (Pantech Burst P9070) | ||
// Weak inference targets Android < 4.4 | ||
if ("isApplicationInstalled" in navigator && "onloadcssdefined" in ss) { | ||
ss.onloadcssdefined(newcb); | ||
} | ||
function loadCSS(url) { | ||
var cssRoot = document.getElementsByTagName('head')[0]; | ||
var link = document.createElement('link'); | ||
link.rel = 'stylesheet'; | ||
link.href = url; | ||
cssRoot.appendChild(link); | ||
return new Promise(function (resolve, reject) { | ||
link.addEventListener('error', function () { | ||
reject("load css error: ".concat(url)); | ||
}); | ||
link.addEventListener('load', function () { | ||
return resolve(link); | ||
}); | ||
}); | ||
} | ||
@@ -172,10 +152,4 @@ | ||
var comboCssUrl = "".concat(baseUrl, "/??").concat(comboCssChunks.join()); | ||
var ss = (0, _fgLoadcss.loadCSS)(comboCssUrl); // @ts-ignore | ||
ss && ss.setAttribute('id', styleId); | ||
return new Promise(function (resolve, reject) { | ||
onloadCSS(ss, function () { | ||
resolve(); | ||
}); | ||
setTimeout(reject, 5000); | ||
return loadCSS(comboCssUrl).then(function (link) { | ||
link && link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b2R1bGUpO1xuICAgICAgICB9IGNhdGNoIChlKSB7XG4gICAgICAgICAgcmVqZWN0KGUpO1xuICAgICAgICB9XG4gICAgICB9KTtcbiAgICB9KTtcbiAgICByZXR1cm4gUHJvbWlzZS5hbGwoW3NzUHJvbWlzZSwganNQcm9taXNlXSkudGhlbigoW3NzLCBtb2R1bGVdKSA9PiB7XG4gICAgICByZXR1cm4gbW9kdWxlO1xuICAgIH0pLmNhdGNoKGUgPT4ge1xuICAgICAgY29uc29sZS53YXJuKCdib290bG9hZCBtb2R1bGUgZXJyb3InLCBlKTtcbiAgICB9KVxuICB9KS5jYXRjaChmdW5jdGlvbiAoZXJyb3I6IGFueSkge1xuICAgIGNvbnNvbGUud2FybignbG9hZCByZW1vdGUgZXJyb3InKTtcbiAgICB0aHJvdyBlcnJvclxuICB9KVxufSJdfQ== |
{ | ||
"name": "webpack-dynamic-require", | ||
"version": "1.0.5", | ||
"version": "1.0.6", | ||
"description": "you can require cdn bundle dynamic", | ||
@@ -42,3 +42,2 @@ "main": "lib/Dynamic.js", | ||
"camelcase": "^5.3.1", | ||
"fg-loadcss": "^2.1.0", | ||
"imurmurhash": "^0.1.4", | ||
@@ -48,2 +47,2 @@ "jsonp-util": "^0.0.1", | ||
} | ||
} | ||
} |
import Scriptjs from 'scriptjs'; | ||
import { loadCSS } from 'fg-loadcss'; | ||
import camelCase from 'camelcase'; | ||
@@ -27,30 +26,17 @@ import MurmurHash3 from 'imurmurhash'; | ||
/*! onloadCSS. (onload callback for loadCSS) [c]2017 Filament Group, Inc. MIT License */ | ||
/* global navigator */ | ||
/* exported onloadCSS */ | ||
function onloadCSS(ss: any, callback?: () => void) { | ||
let called: boolean | undefined; | ||
function newcb() { | ||
if (!called && callback) { | ||
called = true; | ||
callback.call(ss); | ||
} | ||
} | ||
if (ss.addEventListener) { | ||
ss.addEventListener("load", newcb); | ||
} | ||
if (ss.attachEvent) { | ||
ss.attachEvent("onload", newcb); | ||
} | ||
function loadCSS(url: string) { | ||
const cssRoot = document.getElementsByTagName('head')[0]; | ||
const link = document.createElement('link'); | ||
link.rel = 'stylesheet'; | ||
link.href = url; | ||
// This code is for browsers that don’t support onload | ||
// No support for onload (it'll bind but never fire): | ||
// * Android 4.3 (Samsung Galaxy S4, Browserstack) | ||
// * Android 4.2 Browser (Samsung Galaxy SIII Mini GT-I8200L) | ||
// * Android 2.3 (Pantech Burst P9070) | ||
cssRoot.appendChild(link); | ||
// Weak inference targets Android < 4.4 | ||
if ("isApplicationInstalled" in navigator && "onloadcssdefined" in ss) { | ||
ss.onloadcssdefined(newcb); | ||
} | ||
return new Promise<HTMLLinkElement>((resolve, reject) => { | ||
link.addEventListener('error', () => { | ||
reject(`load css error: ${url}`); | ||
}); | ||
link.addEventListener('load', () => resolve(link)); | ||
}); | ||
} | ||
@@ -141,10 +127,4 @@ | ||
const ss = loadCSS(comboCssUrl); | ||
// @ts-ignore | ||
ss && ss.setAttribute('id', styleId); | ||
return new Promise((resolve, reject) => { | ||
onloadCSS(ss, () => { | ||
resolve(); | ||
}); | ||
setTimeout(reject, 5000); | ||
return loadCSS(comboCssUrl).then(link => { | ||
link && link.setAttribute('id', styleId); | ||
}); | ||
@@ -151,0 +131,0 @@ } |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5
75243
803
- Removedfg-loadcss@^2.1.0
- Removedfg-loadcss@2.1.0(transitive)