@lwrjs/view-registry 0.15.7 → 0.15.9
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/build/cjs/linkers/legacy_view_bootstrap.cjs +1 -1
- package/build/cjs/linkers/view_bootstrap.cjs +1 -1
- package/build/cjs/utils.cjs +6 -6
- package/build/es/linkers/legacy_view_bootstrap.js +1 -1
- package/build/es/linkers/view_bootstrap.js +1 -1
- package/build/es/utils.js +6 -7
- package/package.json +7 -7
|
@@ -42,7 +42,7 @@ function includeIdFactory(bundleConfig) {
|
|
|
42
42
|
};
|
|
43
43
|
}
|
|
44
44
|
var moduleGraphsCache = new import_lru_cache.LRUCache({
|
|
45
|
-
max: 500,
|
|
45
|
+
max: parseInt(process.env.MODULE_GRAPH_CACHE_SIZE ?? "500", 10),
|
|
46
46
|
dispose: (_value, key) => {
|
|
47
47
|
if ((0, import_shared_utils.isLambdaEnv)()) {
|
|
48
48
|
import_diagnostics.logger.warn(`Module graph evicted from cache ${key}`);
|
|
@@ -35,7 +35,7 @@ var import_utils2 = __toModule(require("./utils.cjs"));
|
|
|
35
35
|
var import_utils3 = __toModule(require("../utils.cjs"));
|
|
36
36
|
var import_preload_utils = __toModule(require("./preload-utils.cjs"));
|
|
37
37
|
var moduleGraphsCache = new import_lru_cache.LRUCache({
|
|
38
|
-
max: 500,
|
|
38
|
+
max: parseInt(process.env.MODULE_GRAPH_CACHE_SIZE ?? "500", 10),
|
|
39
39
|
dispose: (_value, key) => {
|
|
40
40
|
if ((0, import_shared_utils.isLambdaEnv)()) {
|
|
41
41
|
import_diagnostics.logger.warn(`Module graph evicted from cache ${key}`);
|
package/build/cjs/utils.cjs
CHANGED
|
@@ -350,14 +350,14 @@ function getViewDefCacheKey(view, runtimeEnvironment, freezeAssets, runtimeParam
|
|
|
350
350
|
});
|
|
351
351
|
}
|
|
352
352
|
function getModuleGraphCacheKey(specifier, runtimeEnvironment, runtimeParams) {
|
|
353
|
-
const
|
|
354
|
-
|
|
353
|
+
const params = {
|
|
354
|
+
basePath: runtimeParams.basePath,
|
|
355
|
+
debug: runtimeEnvironment.debug,
|
|
356
|
+
locale: runtimeParams.locale,
|
|
357
|
+
ssr: runtimeParams.ssr
|
|
355
358
|
};
|
|
356
|
-
delete updatedParams.url;
|
|
357
|
-
delete updatedParams.query;
|
|
358
359
|
return (0, import_shared_utils.getCacheKeyFromJson)({
|
|
359
360
|
specifier,
|
|
360
|
-
|
|
361
|
-
runtimeEnvironment
|
|
361
|
+
params
|
|
362
362
|
});
|
|
363
363
|
}
|
|
@@ -19,7 +19,7 @@ function includeIdFactory(bundleConfig) {
|
|
|
19
19
|
// `getModuleGraphs` is very expensive and does not need to be recomputed every time.
|
|
20
20
|
// Note: we use the same cache key passed in from the top level view-registry for consistency
|
|
21
21
|
const moduleGraphsCache = new LRUCache({
|
|
22
|
-
max: 500,
|
|
22
|
+
max: parseInt(process.env.MODULE_GRAPH_CACHE_SIZE ?? '500', 10),
|
|
23
23
|
dispose: (_value, key) => {
|
|
24
24
|
if (isLambdaEnv()) {
|
|
25
25
|
logger.warn(`Module graph evicted from cache ${key}`);
|
|
@@ -9,7 +9,7 @@ import { setPreloadModulesMeta, getPreloadModulesMeta } from './preload-utils.js
|
|
|
9
9
|
// `getModuleGraphs` is very expensive and does not need to be recomputed every time.
|
|
10
10
|
// Note: we use the same cache key passed in from the top level view-registry for consistency
|
|
11
11
|
const moduleGraphsCache = new LRUCache({
|
|
12
|
-
max: 500,
|
|
12
|
+
max: parseInt(process.env.MODULE_GRAPH_CACHE_SIZE ?? '500', 10),
|
|
13
13
|
dispose: (_value, key) => {
|
|
14
14
|
if (isLambdaEnv()) {
|
|
15
15
|
logger.warn(`Module graph evicted from cache ${key}`);
|
package/build/es/utils.js
CHANGED
|
@@ -341,16 +341,15 @@ export function getViewDefCacheKey(view, runtimeEnvironment, freezeAssets, runti
|
|
|
341
341
|
});
|
|
342
342
|
}
|
|
343
343
|
export function getModuleGraphCacheKey(specifier, runtimeEnvironment, runtimeParams) {
|
|
344
|
-
const
|
|
345
|
-
|
|
344
|
+
const params = {
|
|
345
|
+
basePath: runtimeParams.basePath,
|
|
346
|
+
debug: runtimeEnvironment.debug,
|
|
347
|
+
locale: runtimeParams.locale,
|
|
348
|
+
ssr: runtimeParams.ssr,
|
|
346
349
|
};
|
|
347
|
-
// Remove the URL and query from the runtimeParams
|
|
348
|
-
delete updatedParams.url;
|
|
349
|
-
delete updatedParams.query;
|
|
350
350
|
return getCacheKeyFromJson({
|
|
351
351
|
specifier,
|
|
352
|
-
|
|
353
|
-
runtimeEnvironment,
|
|
352
|
+
params,
|
|
354
353
|
});
|
|
355
354
|
}
|
|
356
355
|
//# sourceMappingURL=utils.js.map
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
7
|
-
"version": "0.15.
|
|
7
|
+
"version": "0.15.9",
|
|
8
8
|
"homepage": "https://developer.salesforce.com/docs/platform/lwr/overview",
|
|
9
9
|
"repository": {
|
|
10
10
|
"type": "git",
|
|
@@ -33,14 +33,14 @@
|
|
|
33
33
|
"build": "tsc -b"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@lwrjs/app-service": "0.15.
|
|
37
|
-
"@lwrjs/diagnostics": "0.15.
|
|
38
|
-
"@lwrjs/instrumentation": "0.15.
|
|
39
|
-
"@lwrjs/shared-utils": "0.15.
|
|
36
|
+
"@lwrjs/app-service": "0.15.9",
|
|
37
|
+
"@lwrjs/diagnostics": "0.15.9",
|
|
38
|
+
"@lwrjs/instrumentation": "0.15.9",
|
|
39
|
+
"@lwrjs/shared-utils": "0.15.9",
|
|
40
40
|
"lru-cache": "^10.4.3"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
|
-
"@lwrjs/types": "0.15.
|
|
43
|
+
"@lwrjs/types": "0.15.9"
|
|
44
44
|
},
|
|
45
45
|
"engines": {
|
|
46
46
|
"node": ">=18.0.0"
|
|
@@ -48,5 +48,5 @@
|
|
|
48
48
|
"volta": {
|
|
49
49
|
"extends": "../../../package.json"
|
|
50
50
|
},
|
|
51
|
-
"gitHead": "
|
|
51
|
+
"gitHead": "281108b0e976f7302571a77d7f1d15136b9076e9"
|
|
52
52
|
}
|