@lwrjs/resource-registry 0.6.0 → 0.6.4
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/index.cjs +2 -2
- package/build/es/index.d.ts +1 -1
- package/build/es/index.js +2 -2
- package/package.json +4 -4
package/build/cjs/index.cjs
CHANGED
|
@@ -44,9 +44,9 @@ var LwrResourceRegistry = class {
|
|
|
44
44
|
}
|
|
45
45
|
return void 0;
|
|
46
46
|
}
|
|
47
|
-
resolveResourceUri({specifier, version = ""}, {apiVersion, format}) {
|
|
47
|
+
resolveResourceUri({specifier, version = ""}, {apiVersion, format, basePath}) {
|
|
48
48
|
const versionedSpecifier = (0, import_shared_utils.getSpecifier)({specifier, version: (0, import_shared_utils.normalizeVersionToUri)(version)});
|
|
49
|
-
return
|
|
49
|
+
return `${basePath}/${apiVersion}/resource/${format}/${encodeURIComponent(versionedSpecifier)}`;
|
|
50
50
|
}
|
|
51
51
|
getPublicApi() {
|
|
52
52
|
return {
|
package/build/es/index.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ export declare class LwrResourceRegistry implements ResourceRegistry {
|
|
|
5
5
|
constructor();
|
|
6
6
|
addResourceProviders(providers: ResourceProvider[]): void;
|
|
7
7
|
getResource<T extends ResourceIdentifier, R extends RuntimeEnvironment>(resourceId: T, runtimeEnvironment: R, runtimeParams?: RuntimeParams): Promise<ResourceDefinition | undefined>;
|
|
8
|
-
resolveResourceUri<M extends ResourceIdentifier, R extends RuntimeEnvironment>({ specifier, version }: M, { apiVersion, format }: R): string;
|
|
8
|
+
resolveResourceUri<M extends ResourceIdentifier, R extends RuntimeEnvironment>({ specifier, version }: M, { apiVersion, format, basePath }: R): string;
|
|
9
9
|
getPublicApi(): PublicResourceRegistry;
|
|
10
10
|
}
|
|
11
11
|
//# sourceMappingURL=index.d.ts.map
|
package/build/es/index.js
CHANGED
|
@@ -21,9 +21,9 @@ export class LwrResourceRegistry {
|
|
|
21
21
|
return undefined;
|
|
22
22
|
}
|
|
23
23
|
// Given a resource and environment, return a resource URI
|
|
24
|
-
resolveResourceUri({ specifier, version = '' }, { apiVersion, format }) {
|
|
24
|
+
resolveResourceUri({ specifier, version = '' }, { apiVersion, format, basePath }) {
|
|
25
25
|
const versionedSpecifier = getSpecifier({ specifier, version: normalizeVersionToUri(version) });
|
|
26
|
-
return
|
|
26
|
+
return `${basePath}/${apiVersion}/resource/${format}/${encodeURIComponent(versionedSpecifier)}`;
|
|
27
27
|
}
|
|
28
28
|
getPublicApi() {
|
|
29
29
|
return {
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
7
|
-
"version": "0.6.
|
|
7
|
+
"version": "0.6.4",
|
|
8
8
|
"homepage": "https://developer.salesforce.com/docs/platform/lwr/overview",
|
|
9
9
|
"repository": {
|
|
10
10
|
"type": "git",
|
|
@@ -30,13 +30,13 @@
|
|
|
30
30
|
"build/**/*.d.ts"
|
|
31
31
|
],
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"@lwrjs/shared-utils": "0.6.
|
|
33
|
+
"@lwrjs/shared-utils": "0.6.4"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
|
-
"@lwrjs/types": "0.6.
|
|
36
|
+
"@lwrjs/types": "0.6.4"
|
|
37
37
|
},
|
|
38
38
|
"engines": {
|
|
39
39
|
"node": ">=14.15.4 <17"
|
|
40
40
|
},
|
|
41
|
-
"gitHead": "
|
|
41
|
+
"gitHead": "80b73fe4558dc3db0afcdbe80eb17f5a1464e34e"
|
|
42
42
|
}
|