@lwrjs/types 0.12.0-alpha.20 → 0.12.0-alpha.22
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/config.d.ts +3 -0
- package/build/index.d.ts +7 -3
- package/package.json +2 -2
package/build/config.d.ts
CHANGED
|
@@ -215,6 +215,9 @@ export interface BundleConfig {
|
|
|
215
215
|
alias?: Record<string, string>;
|
|
216
216
|
groups?: BundleGroups;
|
|
217
217
|
}
|
|
218
|
+
export interface ModuleRegistryConfig {
|
|
219
|
+
bundleConfig: BundleConfig;
|
|
220
|
+
}
|
|
218
221
|
export interface BundleConfigOverrides extends BundleConfig {
|
|
219
222
|
appendExcludes?: boolean;
|
|
220
223
|
}
|
package/build/index.d.ts
CHANGED
|
@@ -6,7 +6,7 @@ import type { WatchOptions } from 'chokidar';
|
|
|
6
6
|
import type { EventEmitter } from 'events';
|
|
7
7
|
import type fs from 'fs';
|
|
8
8
|
import type { Readable } from 'stream';
|
|
9
|
-
import type { BundleConfig, EnvironmentConfig, HooksPlugin, LwrLockerConfig, NormalizedLwrErrorRoute, NormalizedLwrGlobalConfig, NormalizedLwrRoute, ResolverModuleRecord, BundleConfigOverrides, RouteHandlers, AssetConfig, I18NConfig } from './config.js';
|
|
9
|
+
import type { BundleConfig, EnvironmentConfig, HooksPlugin, LwrLockerConfig, NormalizedLwrErrorRoute, NormalizedLwrGlobalConfig, NormalizedLwrRoute, ResolverModuleRecord, BundleConfigOverrides, RouteHandlers, AssetConfig, I18NConfig, ModuleRegistryConfig } from './config.js';
|
|
10
10
|
import type { AssetReference, CompiledView, PublicViewRegistry, ViewProvider, ViewRegistry, ViewTransformPlugin } from './views.js';
|
|
11
11
|
export * from './lwr-shim.js';
|
|
12
12
|
export * from './config.js';
|
|
@@ -73,6 +73,7 @@ interface BaseModuleEntry {
|
|
|
73
73
|
id: string;
|
|
74
74
|
entry: string;
|
|
75
75
|
virtual?: boolean;
|
|
76
|
+
external?: boolean;
|
|
76
77
|
scope?: string;
|
|
77
78
|
specifier: Specifier;
|
|
78
79
|
version: Version;
|
|
@@ -92,6 +93,7 @@ export interface BaseModuleReference {
|
|
|
92
93
|
specifier: string;
|
|
93
94
|
version: Version;
|
|
94
95
|
interchangeable?: boolean;
|
|
96
|
+
externalSrc?: string;
|
|
95
97
|
}
|
|
96
98
|
export interface ImportModuleReference extends BaseModuleReference {
|
|
97
99
|
sourceSpecifier: Specifier;
|
|
@@ -283,9 +285,10 @@ export interface ModuleRegistry {
|
|
|
283
285
|
getModuleEntry(moduleId: AbstractModuleId, runtimeParams?: RuntimeParams): Promise<ModuleEntry>;
|
|
284
286
|
resolveModuleUri<R extends RuntimeEnvironment, S extends string | undefined>(moduleId: Required<Pick<ModuleId, 'specifier' | 'version'>>, runtimeEnvironment: R, runtimeParams?: RuntimeParams, signature?: S): Promise<string>;
|
|
285
287
|
resolveModuleUriSync<R extends RuntimeEnvironment, S extends string | undefined>(moduleId: Required<Pick<ModuleId, 'specifier' | 'version'>>, signature: S, runtimeEnvironment: R, runtimeParams?: RuntimeParams): string;
|
|
288
|
+
getConfig(): ModuleRegistryConfig;
|
|
286
289
|
getPublicApi(): PublicModuleRegistry;
|
|
287
290
|
}
|
|
288
|
-
export type PublicModuleRegistry = Pick<ModuleRegistry, 'getModule' | 'getModuleEntry' | 'getLinkedModule' | 'resolveModuleUri'>;
|
|
291
|
+
export type PublicModuleRegistry = Pick<ModuleRegistry, 'getConfig' | 'getModule' | 'getModuleEntry' | 'getLinkedModule' | 'resolveModuleUri'>;
|
|
289
292
|
export interface BundleProvider {
|
|
290
293
|
name: string;
|
|
291
294
|
bundle<T extends AbstractModuleId, R extends RuntimeEnvironment>(moduleId: T, runtimeEnvironment: R, runtimeParams: RuntimeParams, configOverrides?: BundleConfig): Promise<BundleDefinition | undefined>;
|
|
@@ -295,9 +298,10 @@ export interface ModuleBundler {
|
|
|
295
298
|
addBundleTransformers(transformers: UriTransformPlugin[]): void;
|
|
296
299
|
getModuleBundle<T extends AbstractModuleId, R extends RuntimeEnvironment>(moduleId: T, runtimeEnvironment: R, runtimeParams?: RuntimeParams, bundleConfigOverrides?: BundleConfigOverrides): Promise<BundleDefinition>;
|
|
297
300
|
resolveModuleUri(moduleId: Required<Pick<ModuleId, 'specifier' | 'version'>>, runtimeEnvironment: RuntimeEnvironment, runtimeParams?: RuntimeParams, signature?: string): Promise<string>;
|
|
301
|
+
getConfig(): BundleConfig;
|
|
298
302
|
getPublicApi(): PublicModuleBundler;
|
|
299
303
|
}
|
|
300
|
-
export type PublicModuleBundler = Pick<ModuleBundler, 'getModuleBundle' | 'resolveModuleUri'>;
|
|
304
|
+
export type PublicModuleBundler = Pick<ModuleBundler, 'getConfig' | 'getModuleBundle' | 'resolveModuleUri'>;
|
|
301
305
|
export interface BundleRecord {
|
|
302
306
|
imports?: BaseModuleReference[];
|
|
303
307
|
dynamicImports?: BaseDynamicModuleReference[];
|
package/package.json
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
"build": "tsc -b"
|
|
9
9
|
},
|
|
10
10
|
"type": "module",
|
|
11
|
-
"version": "0.12.0-alpha.
|
|
11
|
+
"version": "0.12.0-alpha.22",
|
|
12
12
|
"homepage": "https://developer.salesforce.com/docs/platform/lwr/overview",
|
|
13
13
|
"repository": {
|
|
14
14
|
"type": "git",
|
|
@@ -29,5 +29,5 @@
|
|
|
29
29
|
"engines": {
|
|
30
30
|
"node": ">=18.0.0"
|
|
31
31
|
},
|
|
32
|
-
"gitHead": "
|
|
32
|
+
"gitHead": "6eb804007e93e513d4eb60fd321c088bad3c698e"
|
|
33
33
|
}
|