@atlaspack/runtime-js 2.14.15-alshintegrationtestslib.0 → 2.14.15-dev.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/helpers/browser/css-loader.js +3 -4
- package/lib/helpers/browser/html-loader.js +1 -1
- package/lib/helpers/browser/import-polyfill.js +1 -1
- package/lib/helpers/browser/js-loader.js +3 -4
- package/lib/helpers/browser/prefetch-loader.js +1 -1
- package/lib/helpers/browser/preload-loader.js +1 -1
- package/lib/helpers/browser/wasm-loader.js +1 -1
- package/lib/helpers/cacheLoader.js +1 -1
- package/lib/helpers/conditional-loader-dev.js +1 -1
- package/lib/helpers/conditional-loader.js +1 -1
- package/lib/helpers/get-worker-url.js +1 -1
- package/lib/helpers/node/css-loader.js +1 -1
- package/lib/helpers/node/html-loader.js +1 -1
- package/lib/helpers/node/js-loader.js +1 -1
- package/lib/helpers/node/wasm-loader.js +1 -1
- package/lib/helpers/worker/js-loader.js +1 -1
- package/lib/helpers/worker/wasm-loader.js +1 -1
- package/package.json +7 -7
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
const cacheLoader = require('../cacheLoader');
|
|
4
|
-
module.exports = cacheLoader(function
|
|
4
|
+
module.exports = cacheLoader(function (bundle) {
|
|
5
5
|
return new Promise(function (resolve, reject) {
|
|
6
6
|
// Don't insert the same link element twice (e.g. if it was already in the HTML)
|
|
7
7
|
let existingLinks = document.getElementsByTagName('link');
|
|
8
|
-
|
|
8
|
+
if ([].concat(existingLinks).some(function (link) {
|
|
9
9
|
return link.href === bundle && link.rel.indexOf('stylesheet') > -1;
|
|
10
|
-
}
|
|
11
|
-
if ([].concat(existingLinks).some(isCurrentBundle)) {
|
|
10
|
+
})) {
|
|
12
11
|
resolve();
|
|
13
12
|
return;
|
|
14
13
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
const cacheLoader = require('../cacheLoader');
|
|
4
|
-
module.exports = cacheLoader(function
|
|
4
|
+
module.exports = cacheLoader(function (bundle) {
|
|
5
5
|
return new Promise((resolve, reject) => {
|
|
6
6
|
// Add a global function to handle when the script loads.
|
|
7
7
|
let globalName = `i${('' + Math.random()).slice(2)}`;
|
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
const cacheLoader = require('../cacheLoader');
|
|
4
|
-
module.exports = cacheLoader(function
|
|
4
|
+
module.exports = cacheLoader(function (bundle) {
|
|
5
5
|
return new Promise(function (resolve, reject) {
|
|
6
6
|
// Don't insert the same script twice (e.g. if it was already in the HTML)
|
|
7
7
|
let existingScripts = document.getElementsByTagName('script');
|
|
8
|
-
|
|
8
|
+
if ([].concat(existingScripts).some(function (script) {
|
|
9
9
|
return script.src === bundle;
|
|
10
|
-
}
|
|
11
|
-
if ([].concat(existingScripts).some(isCurrentBundle)) {
|
|
10
|
+
})) {
|
|
12
11
|
resolve();
|
|
13
12
|
return;
|
|
14
13
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
const cacheLoader = require('../cacheLoader');
|
|
4
|
-
module.exports = cacheLoader(function
|
|
4
|
+
module.exports = cacheLoader(function (bundle, priority) {
|
|
5
5
|
var link = document.createElement('link');
|
|
6
6
|
link.rel = 'prefetch';
|
|
7
7
|
link.href = bundle;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
const cacheLoader = require('../cacheLoader');
|
|
4
|
-
module.exports = cacheLoader(function
|
|
4
|
+
module.exports = cacheLoader(function (bundle, priority, isModule) {
|
|
5
5
|
var link = document.createElement('link');
|
|
6
6
|
link.charset = 'utf-8';
|
|
7
7
|
link.rel = isModule ? 'modulepreload' : 'preload';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
const cacheLoader = require('../cacheLoader');
|
|
4
|
-
module.exports = cacheLoader(function
|
|
4
|
+
module.exports = cacheLoader(function (bundle) {
|
|
5
5
|
return fetch(bundle).then(function (res) {
|
|
6
6
|
if (WebAssembly.instantiateStreaming) {
|
|
7
7
|
return WebAssembly.instantiateStreaming(res);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
module.exports = function
|
|
3
|
+
module.exports = function (cond, ifTrue, ifFalse) {
|
|
4
4
|
if (typeof globalThis.__MCOND !== 'function') {
|
|
5
5
|
throw new TypeError('"globalThis.__MCOND" was not set to an object. Ensure the function is set to return the key condition for conditional bundles to load with.');
|
|
6
6
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
module.exports = function
|
|
3
|
+
module.exports = function (workerUrl, origin, isESM) {
|
|
4
4
|
if (origin === self.location.origin) {
|
|
5
5
|
// If the worker bundle's url is on the same origin as the document,
|
|
6
6
|
// use the worker bundle's own url.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
const fs = require('fs');
|
|
4
4
|
const cacheLoader = require('../cacheLoader');
|
|
5
|
-
module.exports = cacheLoader(function
|
|
5
|
+
module.exports = cacheLoader(function (bundle) {
|
|
6
6
|
return new Promise(function (resolve, reject) {
|
|
7
7
|
fs.readFile(__dirname + bundle, 'utf8', function (err, data) {
|
|
8
8
|
if (err) {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
const fs = require('fs');
|
|
4
4
|
const cacheLoader = require('../cacheLoader');
|
|
5
|
-
module.exports = cacheLoader(function
|
|
5
|
+
module.exports = cacheLoader(function (bundle) {
|
|
6
6
|
return new Promise(function (resolve, reject) {
|
|
7
7
|
fs.readFile(__dirname + bundle, 'utf8', function (err, data) {
|
|
8
8
|
if (err) {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
const fs = require('fs');
|
|
4
4
|
const cacheLoader = require('../cacheLoader');
|
|
5
|
-
module.exports = cacheLoader(function
|
|
5
|
+
module.exports = cacheLoader(function (bundle) {
|
|
6
6
|
return new Promise(function (resolve, reject) {
|
|
7
7
|
fs.readFile(__dirname + bundle, function (err, data) {
|
|
8
8
|
if (err) {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
/* global __parcel__importScripts__:readonly*/
|
|
4
4
|
const cacheLoader = require('../cacheLoader');
|
|
5
|
-
module.exports = cacheLoader(function
|
|
5
|
+
module.exports = cacheLoader(function (bundle) {
|
|
6
6
|
return new Promise(function (resolve, reject) {
|
|
7
7
|
try {
|
|
8
8
|
__parcel__importScripts__(bundle);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
const cacheLoader = require('../cacheLoader');
|
|
4
|
-
module.exports = cacheLoader(function
|
|
4
|
+
module.exports = cacheLoader(function (bundle) {
|
|
5
5
|
return fetch(bundle).then(function (res) {
|
|
6
6
|
if (WebAssembly.instantiateStreaming) {
|
|
7
7
|
return WebAssembly.instantiateStreaming(res);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaspack/runtime-js",
|
|
3
|
-
"version": "2.14.15-
|
|
3
|
+
"version": "2.14.15-dev.0",
|
|
4
4
|
"license": "(MIT OR Apache-2.0)",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -15,13 +15,13 @@
|
|
|
15
15
|
"node": ">= 16.0.0"
|
|
16
16
|
},
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@atlaspack/diagnostic": "2.14.2-
|
|
19
|
-
"@atlaspack/domain-sharding": "2.14.2-
|
|
20
|
-
"@atlaspack/feature-flags": "2.18.3-
|
|
21
|
-
"@atlaspack/plugin": "2.14.15-
|
|
22
|
-
"@atlaspack/utils": "2.15.3-
|
|
18
|
+
"@atlaspack/diagnostic": "2.14.2-dev.0",
|
|
19
|
+
"@atlaspack/domain-sharding": "2.14.2-dev.0",
|
|
20
|
+
"@atlaspack/feature-flags": "2.18.3-dev.0",
|
|
21
|
+
"@atlaspack/plugin": "2.14.15-dev.0",
|
|
22
|
+
"@atlaspack/utils": "2.15.3-dev.0",
|
|
23
23
|
"nullthrows": "^1.1.1"
|
|
24
24
|
},
|
|
25
25
|
"type": "commonjs",
|
|
26
|
-
"gitHead": "
|
|
26
|
+
"gitHead": "6ce3565fe038caf52c09fad4e48175829b174571"
|
|
27
27
|
}
|