@module-federation/sdk 0.5.0 → 0.5.2

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/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@module-federation/sdk",
3
- "version": "0.5.0",
3
+ "version": "0.5.2",
4
4
  "license": "MIT",
5
5
  "description": "A sdk for support module federation",
6
6
  "keywords": [
@@ -150,6 +150,10 @@ export interface ModuleFederationPluginOptions {
150
150
  * Share scope name used for all shared modules (defaults to 'default').
151
151
  */
152
152
  shareScope?: string;
153
+ /**
154
+ * load shared strategy(defaults to 'version-first').
155
+ */
156
+ shareStrategy?: SharedStrategy;
153
157
  /**
154
158
  * Modules that should be shared in the share scope. When provided, property names are used to match requested modules in this compilation.
155
159
  */
@@ -291,6 +295,7 @@ export interface SharedObject {
291
295
  */
292
296
  [k: string]: SharedConfig | SharedItem;
293
297
  }
298
+ export type SharedStrategy = 'version-first' | 'loaded-first';
294
299
  /**
295
300
  * Advanced configuration for modules that should be shared in the share scope.
296
301
  */
@@ -319,6 +324,10 @@ export interface SharedConfig {
319
324
  * Share scope name.
320
325
  */
321
326
  shareScope?: string;
327
+ /**
328
+ * load shared strategy(defaults to 'version-first').
329
+ */
330
+ shareStrategy?: SharedStrategy;
322
331
  /**
323
332
  * Allow only a single version of the shared module in share scope (disabled by default).
324
333
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@module-federation/sdk",
3
- "version": "0.5.0",
3
+ "version": "0.5.2",
4
4
  "license": "MIT",
5
5
  "description": "A sdk for support module federation",
6
6
  "keywords": [