@lwrjs/everywhere 0.13.1 → 0.13.3
Sign up to get free protection for your applications and to get access to all the features.
- package/build/__generated_site_amd_modules__/1/application/amd/l/en-US/ai/amd-bootstrap/configuration/ci/-/-/s/fb1d1cfa55c5f3bcef558f1bf03cac53/config.js +12 -0
- package/build/__generated_site_amd_modules__/1/module/amd/1/l/en-US/mi/@lwrjs/app-service/amd-bootstrap/module/amd/v/0_13_3/s/272183c0b6e02561b7c96a1b23473837/@lwrjs_app-service_amd-bootstrap_module_amd.js +14 -0
- package/build/__generated_site_amd_modules__/1/module/amd/1/l/en-US/mi/lwc/v/{7_1_2/s/027fc9cd750ae64e43070ae2b597fad0 → 7_2_0/s/8af0ee539312c02579f2d7488cc0c080}/lwc.js +14 -14
- package/build/__generated_site_amd_modules__/1/module/amd/1/l/en-US/mi/lwr/everywhereAmd/v/{0_13_1 → 0_13_3}/s/cb931ebef2b89dcf8ab51456e3a68864/lwr_everywhereAmd.js +3 -3
- package/build/__generated_site_amd_modules__/1/module/amd/1/l/en-US/mi/lwr/init/v/{0_13_1 → 0_13_3}/s/d7186d4fbbc58762dab0d51cc1f0afb8/lwr_init.js +21 -21
- package/build/__generated_site_amd_modules__/1/module/amd/1/l/en-US/mi/lwr/loader/v/{0_13_1/s/ded190a5e59589e772053998f231183d → 0_13_3/s/ba99bf3c6207290b7c7567f7b8265f8f}/lwr_loader.js +18 -6
- package/build/__generated_site_amd_modules__/1/module/amd/1/l/en-US/mi/lwr/metrics/v/{0_13_1 → 0_13_3}/s/fb8c5dd340c69fdf7ded52d3eba633b9/lwr_metrics.js +1 -1
- package/build/__generated_site_amd_modules__/1/module/amd/1/l/en-US/mi/lwr/preInit/v/{0_13_1 → 0_13_3}/s/ec0fad0e38a96bb0b88c9f4553460347/lwr_preInit.js +1 -1
- package/build/__generated_site_amd_modules__/1/module/amd/1/l/en-US/mi/lwr/profiler/v/{0_13_1 → 0_13_3}/s/a152b8d35f12ca1b5147c5cd1ee155fb/lwr_profiler.js +1 -1
- package/build/__generated_site_amd_modules__/1/module/amd/1/l/en-US/mi/lwr/vault/v/{0_13_1 → 0_13_3}/s/c92abd8c1fec2d7eff62e4b097abbe14/lwr_vault.js +1 -1
- package/build/__generated_site_amd_modules__/1/resource/amd/lwr-error-shim.js/v/{0_13_1 → 0_13_3}/lwr-error-shim.js +1 -1
- package/build/__generated_site_amd_modules__/1/resource/amd/lwr-loader-shim.bundle.js/v/{0_13_1 → 0_13_3}/lwr-loader-shim.bundle.js +25 -9
- package/build/assets/amd/lwr-everywhere-debug.js +27 -11
- package/build/assets/amd/lwr-everywhere-min.js +2 -2
- package/build/assets/amd/lwr-everywhere.js +27 -11
- package/build/assets/core/lwr-everywhere-debug.js +23 -7
- package/build/assets/core/lwr-everywhere-min.js +2 -2
- package/build/assets/core/lwr-everywhere.js +23 -7
- package/build/assets/esm/lwr-everywhere-debug.js +1 -1
- package/build/assets/esm/lwr-everywhere-min.js +1 -1
- package/build/assets/esm/lwr-everywhere.js +1 -1
- package/package.json +7 -7
- package/build/__generated_site_amd_modules__/1/application/amd/l/en-US/ai/amd-bootstrap/configuration/ci/-/-/s/3843d81d518e535e74becaf4861cf364/config.js +0 -12
- package/build/__generated_site_amd_modules__/1/module/amd/1/l/en-US/mi/@lwrjs/app-service/amd-bootstrap/module/amd/v/0_13_1/s/272183c0b6e02561b7c96a1b23473837/@lwrjs_app-service_amd-bootstrap_module_amd.js +0 -14
@@ -52,7 +52,7 @@ function getConfiguration(options) {
|
|
52
52
|
* SPDX-License-Identifier: MIT
|
53
53
|
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
|
54
54
|
*/
|
55
|
-
/* LWR Module Loader v0.13.
|
55
|
+
/* LWR Module Loader v0.13.3 */
|
56
56
|
const templateRegex = /\{([0-9]+)\}/g;
|
57
57
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
58
58
|
function templateString(template, args) {
|
@@ -200,7 +200,11 @@ const hasDocument = typeof document !== 'undefined';
|
|
200
200
|
const hasSetTimeout = typeof setTimeout === 'function';
|
201
201
|
|
202
202
|
const hasConsole = typeof console !== 'undefined';
|
203
|
-
|
203
|
+
|
204
|
+
const hasProcess = typeof process !== 'undefined';
|
205
|
+
|
206
|
+
// eslint-disable-next-line no-undef
|
207
|
+
const hasProcessEnv = hasProcess && process.env;
|
204
208
|
|
205
209
|
function getBaseUrl() {
|
206
210
|
let baseUrl = undefined;
|
@@ -702,7 +706,7 @@ try {
|
|
702
706
|
// swallow
|
703
707
|
}
|
704
708
|
const trusted = createPolicy('trusted', policyOptions);
|
705
|
-
/*! version: 0.22.
|
709
|
+
/*! version: 0.22.5 */
|
706
710
|
|
707
711
|
/* global console,process */
|
708
712
|
|
@@ -714,6 +718,7 @@ if (hasDocument) {
|
|
714
718
|
});
|
715
719
|
}
|
716
720
|
|
721
|
+
// eslint-disable-next-line lwr/no-unguarded-apis
|
717
722
|
if (process.env.NODE_ENV !== 'production') {
|
718
723
|
if (!hasSetTimeout && hasConsole) {
|
719
724
|
// eslint-disable-next-line lwr/no-unguarded-apis
|
@@ -773,6 +778,7 @@ async function evaluateLoadHookResponse(response, id) {
|
|
773
778
|
// TODO eval source maps for debugging
|
774
779
|
eval(trusted.createScript(code));
|
775
780
|
} catch (e) {
|
781
|
+
// eslint-disable-next-line lwr/no-unguarded-apis
|
776
782
|
if (process.env.NODE_ENV !== 'production' && hasConsole) {
|
777
783
|
// eslint-disable-next-line lwr/no-unguarded-apis
|
778
784
|
console.error(e);
|
@@ -994,7 +1000,14 @@ class ModuleRegistry {
|
|
994
1000
|
const mod = this.namedDefineRegistry.get(name);
|
995
1001
|
// Don't allow redefining a module.
|
996
1002
|
if (mod && mod.defined) {
|
997
|
-
if (
|
1003
|
+
if (
|
1004
|
+
hasProcessEnv &&
|
1005
|
+
// eslint-disable-next-line lwr/no-unguarded-apis
|
1006
|
+
process.env.NODE_ENV !== 'production' &&
|
1007
|
+
// eslint-disable-next-line lwr/no-unguarded-apis
|
1008
|
+
process.env.MRT_HMR !== 'true' &&
|
1009
|
+
hasConsole
|
1010
|
+
) {
|
998
1011
|
// eslint-disable-next-line lwr/no-unguarded-apis
|
999
1012
|
console.warn(`Module redefine attempted: ${name}`);
|
1000
1013
|
}
|
@@ -1049,6 +1062,7 @@ class ModuleRegistry {
|
|
1049
1062
|
},
|
1050
1063
|
};
|
1051
1064
|
this.namedDefineRegistry.set(id, moduleDef );
|
1065
|
+
// eslint-disable-next-line lwr/no-unguarded-apis
|
1052
1066
|
} else if (process.env.NODE_ENV !== 'production' && hasConsole) {
|
1053
1067
|
// eslint-disable-next-line lwr/no-unguarded-apis
|
1054
1068
|
console.warn(MODULE_ALREADY_LOADED.message, id);
|
@@ -1140,6 +1154,7 @@ class ModuleRegistry {
|
|
1140
1154
|
if (aliasId !== resolvedId) {
|
1141
1155
|
if (!this.aliases.has(aliasId)) {
|
1142
1156
|
this.aliases.set(aliasId, resolvedId);
|
1157
|
+
// eslint-disable-next-line lwr/no-unguarded-apis, no-undef
|
1143
1158
|
} else if (process.env.NODE_ENV !== 'production' && hasConsole) {
|
1144
1159
|
// Warn the user if they were not aliasing to the resolvedId
|
1145
1160
|
const currentResolvedId = this.aliases.get(aliasId);
|
@@ -1438,6 +1453,7 @@ class ModuleRegistry {
|
|
1438
1453
|
newUrl,
|
1439
1454
|
});
|
1440
1455
|
} else {
|
1456
|
+
// eslint-disable-next-line lwr/no-unguarded-apis
|
1441
1457
|
if (process.env.NODE_ENV !== 'production' && hasConsole) {
|
1442
1458
|
// eslint-disable-next-line lwr/no-unguarded-apis, no-undef
|
1443
1459
|
console.warn(`stale module detected ${name}, current URL:${oldUrl}, new URL:${newUrl}`);
|
@@ -1615,12 +1631,12 @@ await loader.registerImportMappings({ imports, index }, [bootstrapModule]);
|
|
1615
1631
|
(globalThis ).LWR = Object.freeze({ define: loader.define.bind(loader) });
|
1616
1632
|
|
1617
1633
|
// Define preload modules (ie: ABS, vault, etc) BEFORE loading them
|
1618
|
-
LWR.define('lwr/everywhereAmd/v/0_0_1', ['exports', 'lwr/vault/v/0_0_1'], (function (exports,
|
1634
|
+
LWR.define('lwr/everywhereAmd/v/0_0_1', ['exports', 'lwr/vault/v/0_0_1'], (function (exports, _0_13_3) {
|
1619
1635
|
// IMPORTANT: Do not add any static imports to this file that are not bundled with the amd-client
|
1620
1636
|
|
1621
1637
|
// Do an OAuthed fetch
|
1622
1638
|
async function authFetch(url, accept = 'javascript') {
|
1623
|
-
const authInfo =
|
1639
|
+
const authInfo = _0_13_3.getAuthInfo();
|
1624
1640
|
if (authInfo) {
|
1625
1641
|
return fetch(url, {
|
1626
1642
|
headers: {
|
@@ -1669,7 +1685,7 @@ LWR.define('lwr/everywhereAmd/v/0_0_1', ['exports', 'lwr/vault/v/0_0_1'], (funct
|
|
1669
1685
|
function authenticate(authInfo) {
|
1670
1686
|
// Put OAuth info into the vault
|
1671
1687
|
if (authInfo) {
|
1672
|
-
|
1688
|
+
_0_13_3.setAuthInfo(authInfo);
|
1673
1689
|
}
|
1674
1690
|
}
|
1675
1691
|
|
@@ -20,7 +20,7 @@ function getConfiguration(options) {
|
|
20
20
|
: `${ORIGIN}${PREFIX}/module/${format}/${POSTFIX}/mi/`;
|
21
21
|
|
22
22
|
// Component specifiers and URIs
|
23
|
-
const BOOT_MODULE = `lwr/everywhere${format === 'esm' ? 'Esm' : 'Amd'}/v/
|
23
|
+
const BOOT_MODULE = `lwr/everywhere${format === 'esm' ? 'Esm' : 'Amd'}/v/0_13_3`;
|
24
24
|
const BOOT_URI = `${ENDPOINT}${encodeURIComponent(BOOT_MODULE)}/latest${debug ? '?debug' : ''}`;
|
25
25
|
|
26
26
|
// Client Bootstrap Config
|
@@ -1 +1 @@
|
|
1
|
-
globalThis.process={env:{NODE_ENV:"production"}};const e=function(e){const{format:o,server:i,apiVersion:n,apiPrefix:t,locale:p,bundle:r,debug:s}=e,m=new URL(import.meta.url),d=i||m.origin||"",a=`${t}/${n}`,$="0"+(p?`/l/${p}`:""),u="/bi/3_A,B,O,S,EG,JLMT,C,D,F,H,I,K,N,P,Q,R",l=r?`${d}${a}/bundle/${o}/${$}${u}-0/module/mi/`:`${d}${a}/module/${o}/${$}/mi/`,b=`lwr/everywhere${"esm"===o?"Esm":"Amd"}/v/
|
1
|
+
globalThis.process={env:{NODE_ENV:"production"}};const e=function(e){const{format:o,server:i,apiVersion:n,apiPrefix:t,locale:p,bundle:r,debug:s}=e,m=new URL(import.meta.url),d=i||m.origin||"",a=`${t}/${n}`,$="0"+(p?`/l/${p}`:""),u="/bi/3_A,B,O,S,EG,JLMT,C,D,F,H,I,K,N,P,Q,R",l=r?`${d}${a}/bundle/${o}/${$}${u}-0/module/mi/`:`${d}${a}/module/${o}/${$}/mi/`,b=`lwr/everywhere${"esm"===o?"Esm":"Amd"}/v/0_13_3`,g=`${l}${encodeURIComponent(b)}/latest${s?"?debug":""}`,c={appId:"lwre",autoBoot:!0,bootstrapModule:b,baseUrl:d,imports:{[g]:[b]},index:{[b]:g},endpoints:{uris:{module:l,mapping:`${d}${a}/mapping/${o}/${$}${r?u:""}/mp/`}}};return s&&c.endpoints&&(c.endpoints.modifiers={debug:"true"}),c}({format:"esm",apiVersion:"1",apiPrefix:"",bundle:!0,debug:!1}),{bootstrapModule:o,imports:i,index:n={},importMappings:t,endpoints:p}=e,{initEsm:r,authenticate:s,createComponent:m}=await import(n[o]);r({imports:i,index:n,importMappings:t,endpoints:p});export{s as authenticate,m as createComponent};
|
@@ -20,7 +20,7 @@ function getConfiguration(options) {
|
|
20
20
|
: `${ORIGIN}${PREFIX}/module/${format}/${POSTFIX}/mi/`;
|
21
21
|
|
22
22
|
// Component specifiers and URIs
|
23
|
-
const BOOT_MODULE = `lwr/everywhere${format === 'esm' ? 'Esm' : 'Amd'}/v/
|
23
|
+
const BOOT_MODULE = `lwr/everywhere${format === 'esm' ? 'Esm' : 'Amd'}/v/0_13_3`;
|
24
24
|
const BOOT_URI = `${ENDPOINT}${encodeURIComponent(BOOT_MODULE)}/latest${debug ? '?debug' : ''}`;
|
25
25
|
|
26
26
|
// Client Bootstrap Config
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@lwrjs/everywhere",
|
3
3
|
"description": "LWR Everywhere",
|
4
|
-
"version": "0.13.
|
4
|
+
"version": "0.13.3",
|
5
5
|
"license": "MIT",
|
6
6
|
"publishConfig": {
|
7
7
|
"access": "public"
|
@@ -50,11 +50,11 @@
|
|
50
50
|
"@salesforce/lds-default-luvio": "1.307.0"
|
51
51
|
},
|
52
52
|
"devDependencies": {
|
53
|
-
"@locker/trusted-types": "0.22.
|
54
|
-
"@lwrjs/loader": "0.13.
|
55
|
-
"@lwrjs/router": "0.13.
|
56
|
-
"@lwrjs/types": "0.13.
|
57
|
-
"lwr": "0.13.
|
53
|
+
"@locker/trusted-types": "0.22.5",
|
54
|
+
"@lwrjs/loader": "0.13.3",
|
55
|
+
"@lwrjs/router": "0.13.3",
|
56
|
+
"@lwrjs/types": "0.13.3",
|
57
|
+
"lwr": "0.13.3"
|
58
58
|
},
|
59
59
|
"peerDependencies": {
|
60
60
|
"@lwc/module-resolver": ">= 2.x"
|
@@ -81,5 +81,5 @@
|
|
81
81
|
"engines": {
|
82
82
|
"node": ">=18.0.0"
|
83
83
|
},
|
84
|
-
"gitHead": "
|
84
|
+
"gitHead": "adaedf286df20aed374d9eb07eaf74668084073c"
|
85
85
|
}
|
@@ -1,12 +0,0 @@
|
|
1
|
-
/* This script is generated */
|
2
|
-
/* Client Bootstrap configuration */
|
3
|
-
globalThis.LWR = globalThis.LWR || {};
|
4
|
-
Object.assign(globalThis.LWR, {"appId":"amd-bootstrap","bootstrapModule":"@lwrjs/app-service/amd-bootstrap/module/amd/v/0_13_1","autoBoot":true,"imports":{"/1/module/amd/1/l/en-US/mi/%40lwrjs%2Fapp-service%2Famd-bootstrap%2Fmodule%2Famd%2Fv%2F0_13_1/s/272183c0b6e02561b7c96a1b23473837/@lwrjs_app-service_amd-bootstrap_module_amd.js":["@lwrjs/app-service/amd-bootstrap/module/amd/v/0_13_1"],"/1/module/amd/1/l/en-US/mi/lwr%2FpreInit%2Fv%2F0_13_1/s/ec0fad0e38a96bb0b88c9f4553460347/lwr_preInit.js":["lwr/preInit/v/0_13_1"],"/1/module/amd/1/l/en-US/mi/lwr%2Finit%2Fv%2F0_13_1/s/d7186d4fbbc58762dab0d51cc1f0afb8/lwr_init.js":["lwr/init/v/0_13_1"],"/1/module/amd/1/l/en-US/mi/lwr%2Fmetrics%2Fv%2F0_13_1/s/fb8c5dd340c69fdf7ded52d3eba633b9/lwr_metrics.js":["lwr/metrics/v/0_13_1"],"/1/module/amd/1/l/en-US/mi/lwc%2Fv%2F7_1_2/s/027fc9cd750ae64e43070ae2b597fad0/lwc.js":["lwc/v/7_1_2"],"/1/module/amd/1/l/en-US/mi/lwr%2FeverywhereAmd%2Fv%2F0_13_1/s/cb931ebef2b89dcf8ab51456e3a68864/lwr_everywhereAmd.js":["lwr/everywhereAmd/v/0_13_1"],"/1/module/amd/1/l/en-US/mi/lwr%2Fvault%2Fv%2F0_13_1/s/c92abd8c1fec2d7eff62e4b097abbe14/lwr_vault.js":["lwr/vault/v/0_13_1"]},"index":{"@lwrjs/app-service/amd-bootstrap/module/amd/v/0_13_1":"/1/module/amd/1/l/en-US/mi/%40lwrjs%2Fapp-service%2Famd-bootstrap%2Fmodule%2Famd%2Fv%2F0_13_1/s/272183c0b6e02561b7c96a1b23473837/@lwrjs_app-service_amd-bootstrap_module_amd.js","lwr/preInit/v/0_13_1":"/1/module/amd/1/l/en-US/mi/lwr%2FpreInit%2Fv%2F0_13_1/s/ec0fad0e38a96bb0b88c9f4553460347/lwr_preInit.js","lwr/init/v/0_13_1":"/1/module/amd/1/l/en-US/mi/lwr%2Finit%2Fv%2F0_13_1/s/d7186d4fbbc58762dab0d51cc1f0afb8/lwr_init.js","lwr/metrics/v/0_13_1":"/1/module/amd/1/l/en-US/mi/lwr%2Fmetrics%2Fv%2F0_13_1/s/fb8c5dd340c69fdf7ded52d3eba633b9/lwr_metrics.js","lwc/v/7_1_2":"/1/module/amd/1/l/en-US/mi/lwc%2Fv%2F7_1_2/s/027fc9cd750ae64e43070ae2b597fad0/lwc.js","lwr/everywhereAmd/v/0_13_1":"/1/module/amd/1/l/en-US/mi/lwr%2FeverywhereAmd%2Fv%2F0_13_1/s/cb931ebef2b89dcf8ab51456e3a68864/lwr_everywhereAmd.js","lwr/vault/v/0_13_1":"/1/module/amd/1/l/en-US/mi/lwr%2Fvault%2Fv%2F0_13_1/s/c92abd8c1fec2d7eff62e4b097abbe14/lwr_vault.js"},"rootComponents":["lwr/everywhereAmd/v/0_13_1"],"serverData":{},"requiredModules":["@lwrjs/app-service/amd-bootstrap/module/amd/v/0_13_1"],"preloadModules":["lwr/preInit/v/0_13_1","lwr/init/v/0_13_1","lwr/metrics/v/0_13_1","lwc/v/7_1_2","lwr/everywhereAmd/v/0_13_1"],"endpoints":{"uris":{"mapping":"/1/mapping/amd/1/l/en-US/mp/"}}});
|
5
|
-
globalThis.LWR = {...globalThis.LWR, env: {"SSR":false,"basePath":"","locale":"en-US","assetBasePath":"","uiBasePath":""}};
|
6
|
-
globalThis.process={...globalThis.process,env:{...globalThis.process?.env,...{"NODE_ENV":"compat"}}};
|
7
|
-
globalThis.lwcRuntimeFlags = { ENABLE_MIXED_SHADOW_MODE: false };
|
8
|
-
// Appended by Static Site Generator
|
9
|
-
if (!globalThis.LWR.imports) { globalThis.LWR.imports = {}; }
|
10
|
-
Object.assign(globalThis.LWR.imports, {"/1/module/amd/1/l/en-US/mi/lwr%2Fprofiler%2Fv%2F0_13_1/s/a152b8d35f12ca1b5147c5cd1ee155fb/lwr_profiler.js":["lwr/profiler/v/0_13_1"],"/1/module/amd/1/l/en-US/mi/lwr%2Floader%2Fv%2F0_13_1/s/ded190a5e59589e772053998f231183d/lwr_loader.js":["lwr/loader/v/0_13_1"]})
|
11
|
-
if (!globalThis.LWR.index) { globalThis.LWR.index = {}; }
|
12
|
-
Object.assign(globalThis.LWR.index, {"lwr/profiler/v/0_13_1":"/1/module/amd/1/l/en-US/mi/lwr%2Fprofiler%2Fv%2F0_13_1/s/a152b8d35f12ca1b5147c5cd1ee155fb/lwr_profiler.js","lwr/loader/v/0_13_1":"/1/module/amd/1/l/en-US/mi/lwr%2Floader%2Fv%2F0_13_1/s/ded190a5e59589e772053998f231183d/lwr_loader.js"})
|
@@ -1,14 +0,0 @@
|
|
1
|
-
LWR.define('@lwrjs/app-service/amd-bootstrap/module/amd/v/0_13_1', ['lwr/loader/v/0_13_1', 'lwr/preInit/v/0_13_1', 'lwr/init/v/0_13_1'], (function (_0_13_1$2, _0_13_1, _0_13_1$1) { 'use strict';
|
2
|
-
|
3
|
-
const clientBootstrapConfig = _0_13_1.getClientBootstrapConfig();
|
4
|
-
const { serverData, rootComponents } = clientBootstrapConfig;
|
5
|
-
|
6
|
-
// initialize additional non-configured root components
|
7
|
-
Promise.all(rootComponents.map(async (rootSpecifier) => {
|
8
|
-
const element = _0_13_1$1.toKebabCase(rootSpecifier);
|
9
|
-
return _0_13_1$2.load(rootSpecifier, '@lwrjs/app-service/amd-bootstrap/module/amd/v/0_13_1').then(({default: Ctor}) => {
|
10
|
-
_0_13_1$1.init([[element, Ctor]], serverData);
|
11
|
-
});
|
12
|
-
}));
|
13
|
-
|
14
|
-
}));
|