@module-federation/runtime 0.6.8 → 0.6.10

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/index.cjs.js CHANGED
@@ -456,8 +456,7 @@ class SyncWaterfallHook extends SyncHook {
456
456
  return data;
457
457
  }
458
458
  constructor(type){
459
- super();
460
- this.onerror = share.error;
459
+ super(), this.onerror = share.error;
461
460
  this.type = type;
462
461
  }
463
462
  }
@@ -495,8 +494,7 @@ class AsyncWaterfallHook extends SyncHook {
495
494
  return Promise.resolve(data);
496
495
  }
497
496
  constructor(type){
498
- super();
499
- this.onerror = share.error;
497
+ super(), this.onerror = share.error;
500
498
  this.type = type;
501
499
  }
502
500
  }
@@ -604,13 +602,14 @@ useLinkPreload = true) {
604
602
  if (useLinkPreload) {
605
603
  const defaultAttrs = {
606
604
  rel: 'preload',
607
- as: 'style',
608
- crossorigin: 'anonymous'
605
+ as: 'style'
609
606
  };
610
607
  cssAssets.forEach((cssUrl)=>{
611
608
  const { link: cssEl, needAttach } = sdk.createLink({
612
609
  url: cssUrl,
613
- cb: ()=>{},
610
+ cb: ()=>{
611
+ // noop
612
+ },
614
613
  attrs: defaultAttrs,
615
614
  createLinkHook: (url, attrs)=>{
616
615
  const res = host.loaderHook.lifecycle.createLink.emit({
@@ -633,7 +632,9 @@ useLinkPreload = true) {
633
632
  cssAssets.forEach((cssUrl)=>{
634
633
  const { link: cssEl, needAttach } = sdk.createLink({
635
634
  url: cssUrl,
636
- cb: ()=>{},
635
+ cb: ()=>{
636
+ // noop
637
+ },
637
638
  attrs: defaultAttrs,
638
639
  createLinkHook: (url, attrs)=>{
639
640
  const res = host.loaderHook.lifecycle.createLink.emit({
@@ -653,13 +654,14 @@ useLinkPreload = true) {
653
654
  if (useLinkPreload) {
654
655
  const defaultAttrs = {
655
656
  rel: 'preload',
656
- as: 'script',
657
- crossorigin: 'anonymous'
657
+ as: 'script'
658
658
  };
659
659
  jsAssetsWithoutEntry.forEach((jsUrl)=>{
660
660
  const { link: linkEl, needAttach } = sdk.createLink({
661
661
  url: jsUrl,
662
- cb: ()=>{},
662
+ cb: ()=>{
663
+ // noop
664
+ },
663
665
  attrs: defaultAttrs,
664
666
  createLinkHook: (url, attrs)=>{
665
667
  const res = host.loaderHook.lifecycle.createLink.emit({
@@ -682,7 +684,9 @@ useLinkPreload = true) {
682
684
  jsAssetsWithoutEntry.forEach((jsUrl)=>{
683
685
  const { script: scriptEl, needAttach } = sdk.createScript({
684
686
  url: jsUrl,
685
- cb: ()=>{},
687
+ cb: ()=>{
688
+ // noop
689
+ },
686
690
  attrs: defaultAttrs,
687
691
  createScriptHook: (url, attrs)=>{
688
692
  const res = host.loaderHook.lifecycle.createScript.emit({
@@ -1987,7 +1991,7 @@ class FederationHost {
1987
1991
  // maybe will change, temporarily for internal use only
1988
1992
  initContainer: new AsyncWaterfallHook('initContainer')
1989
1993
  });
1990
- this.version = "0.6.8";
1994
+ this.version = "0.6.10";
1991
1995
  this.moduleCache = new Map();
1992
1996
  this.loaderHook = new PluginSystem({
1993
1997
  // FIXME: may not be suitable , not open to the public yet
package/dist/index.esm.js CHANGED
@@ -456,8 +456,7 @@ class SyncWaterfallHook extends SyncHook {
456
456
  return data;
457
457
  }
458
458
  constructor(type){
459
- super();
460
- this.onerror = error;
459
+ super(), this.onerror = error;
461
460
  this.type = type;
462
461
  }
463
462
  }
@@ -495,8 +494,7 @@ class AsyncWaterfallHook extends SyncHook {
495
494
  return Promise.resolve(data);
496
495
  }
497
496
  constructor(type){
498
- super();
499
- this.onerror = error;
497
+ super(), this.onerror = error;
500
498
  this.type = type;
501
499
  }
502
500
  }
@@ -604,13 +602,14 @@ useLinkPreload = true) {
604
602
  if (useLinkPreload) {
605
603
  const defaultAttrs = {
606
604
  rel: 'preload',
607
- as: 'style',
608
- crossorigin: 'anonymous'
605
+ as: 'style'
609
606
  };
610
607
  cssAssets.forEach((cssUrl)=>{
611
608
  const { link: cssEl, needAttach } = createLink({
612
609
  url: cssUrl,
613
- cb: ()=>{},
610
+ cb: ()=>{
611
+ // noop
612
+ },
614
613
  attrs: defaultAttrs,
615
614
  createLinkHook: (url, attrs)=>{
616
615
  const res = host.loaderHook.lifecycle.createLink.emit({
@@ -633,7 +632,9 @@ useLinkPreload = true) {
633
632
  cssAssets.forEach((cssUrl)=>{
634
633
  const { link: cssEl, needAttach } = createLink({
635
634
  url: cssUrl,
636
- cb: ()=>{},
635
+ cb: ()=>{
636
+ // noop
637
+ },
637
638
  attrs: defaultAttrs,
638
639
  createLinkHook: (url, attrs)=>{
639
640
  const res = host.loaderHook.lifecycle.createLink.emit({
@@ -653,13 +654,14 @@ useLinkPreload = true) {
653
654
  if (useLinkPreload) {
654
655
  const defaultAttrs = {
655
656
  rel: 'preload',
656
- as: 'script',
657
- crossorigin: 'anonymous'
657
+ as: 'script'
658
658
  };
659
659
  jsAssetsWithoutEntry.forEach((jsUrl)=>{
660
660
  const { link: linkEl, needAttach } = createLink({
661
661
  url: jsUrl,
662
- cb: ()=>{},
662
+ cb: ()=>{
663
+ // noop
664
+ },
663
665
  attrs: defaultAttrs,
664
666
  createLinkHook: (url, attrs)=>{
665
667
  const res = host.loaderHook.lifecycle.createLink.emit({
@@ -682,7 +684,9 @@ useLinkPreload = true) {
682
684
  jsAssetsWithoutEntry.forEach((jsUrl)=>{
683
685
  const { script: scriptEl, needAttach } = createScript({
684
686
  url: jsUrl,
685
- cb: ()=>{},
687
+ cb: ()=>{
688
+ // noop
689
+ },
686
690
  attrs: defaultAttrs,
687
691
  createScriptHook: (url, attrs)=>{
688
692
  const res = host.loaderHook.lifecycle.createScript.emit({
@@ -1987,7 +1991,7 @@ class FederationHost {
1987
1991
  // maybe will change, temporarily for internal use only
1988
1992
  initContainer: new AsyncWaterfallHook('initContainer')
1989
1993
  });
1990
- this.version = "0.6.8";
1994
+ this.version = "0.6.10";
1991
1995
  this.moduleCache = new Map();
1992
1996
  this.loaderHook = new PluginSystem({
1993
1997
  // FIXME: may not be suitable , not open to the public yet
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@module-federation/runtime",
3
- "version": "0.6.8",
3
+ "version": "0.6.10",
4
4
  "author": "zhouxiao <codingzx@gmail.com>",
5
5
  "main": "./index.cjs.js",
6
6
  "module": "./index.esm.js",
package/dist/share.cjs.js CHANGED
@@ -175,7 +175,7 @@ function getGlobalFederationConstructor() {
175
175
  function setGlobalFederationConstructor(FederationConstructor, isDebug = sdk.isDebugMode()) {
176
176
  if (isDebug) {
177
177
  globalThis.__FEDERATION__.__DEBUG_CONSTRUCTOR__ = FederationConstructor;
178
- globalThis.__FEDERATION__.__DEBUG_CONSTRUCTOR_VERSION__ = "0.6.8";
178
+ globalThis.__FEDERATION__.__DEBUG_CONSTRUCTOR_VERSION__ = "0.6.10";
179
179
  }
180
180
  }
181
181
  // eslint-disable-next-line @typescript-eslint/ban-types
package/dist/share.esm.js CHANGED
@@ -173,7 +173,7 @@ function getGlobalFederationConstructor() {
173
173
  function setGlobalFederationConstructor(FederationConstructor, isDebug = isDebugMode()) {
174
174
  if (isDebug) {
175
175
  globalThis.__FEDERATION__.__DEBUG_CONSTRUCTOR__ = FederationConstructor;
176
- globalThis.__FEDERATION__.__DEBUG_CONSTRUCTOR_VERSION__ = "0.6.8";
176
+ globalThis.__FEDERATION__.__DEBUG_CONSTRUCTOR_VERSION__ = "0.6.10";
177
177
  }
178
178
  }
179
179
  // eslint-disable-next-line @typescript-eslint/ban-types
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@module-federation/runtime",
3
- "version": "0.6.8",
3
+ "version": "0.6.10",
4
4
  "author": "zhouxiao <codingzx@gmail.com>",
5
5
  "main": "./dist/index.cjs.js",
6
6
  "module": "./dist/index.esm.js",
@@ -50,6 +50,6 @@
50
50
  }
51
51
  },
52
52
  "dependencies": {
53
- "@module-federation/sdk": "0.6.8"
53
+ "@module-federation/sdk": "0.6.10"
54
54
  }
55
55
  }