@module-federation/modern-js 0.0.0-next-20240530073428 → 0.0.0-next-20240530085615

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.
@@ -111,21 +111,23 @@ function collectAssets(options) {
111
111
  href: `${publicPath}${file}`,
112
112
  rel: "stylesheet",
113
113
  type: "text/css"
114
- }, index));
114
+ }, `${file.split(".")[0]}_${index}`));
115
115
  });
116
116
  }
117
117
  if (injectScript) {
118
118
  scripts.push(/* @__PURE__ */ (0, import_jsx_runtime.jsx)("script", {
119
+ async: true,
119
120
  src: `${publicPath}${remoteEntry}`,
120
121
  crossOrigin: "anonymous"
121
- }, "remote-entry"));
122
+ }, remoteEntry.split(".")[0]));
122
123
  [
123
124
  ...targetModule.assets.js.sync
124
125
  ].forEach((file, index) => {
125
126
  scripts.push(/* @__PURE__ */ (0, import_jsx_runtime.jsx)("script", {
127
+ async: true,
126
128
  src: `${publicPath}${file}`,
127
129
  crossOrigin: "anonymous"
128
- }, index));
130
+ }, `${file.split(".")[0]}_${index}`));
129
131
  });
130
132
  }
131
133
  return [
@@ -72,19 +72,21 @@ function collectAssets(options) {
72
72
  href: "".concat(publicPath).concat(file),
73
73
  rel: "stylesheet",
74
74
  type: "text/css"
75
- }, index));
75
+ }, "".concat(file.split(".")[0], "_").concat(index)));
76
76
  });
77
77
  }
78
78
  if (injectScript) {
79
79
  scripts.push(/* @__PURE__ */ _jsx("script", {
80
+ async: true,
80
81
  src: "".concat(publicPath).concat(remoteEntry),
81
82
  crossOrigin: "anonymous"
82
- }, "remote-entry"));
83
+ }, remoteEntry.split(".")[0]));
83
84
  _to_consumable_array(targetModule.assets.js.sync).forEach(function(file, index) {
84
85
  scripts.push(/* @__PURE__ */ _jsx("script", {
86
+ async: true,
85
87
  src: "".concat(publicPath).concat(file),
86
88
  crossOrigin: "anonymous"
87
- }, index));
89
+ }, "".concat(file.split(".")[0], "_").concat(index)));
88
90
  });
89
91
  }
90
92
  return _to_consumable_array(scripts).concat(_to_consumable_array(links));
@@ -77,21 +77,23 @@ function collectAssets(options) {
77
77
  href: `${publicPath}${file}`,
78
78
  rel: "stylesheet",
79
79
  type: "text/css"
80
- }, index));
80
+ }, `${file.split(".")[0]}_${index}`));
81
81
  });
82
82
  }
83
83
  if (injectScript) {
84
84
  scripts.push(/* @__PURE__ */ _jsx("script", {
85
+ async: true,
85
86
  src: `${publicPath}${remoteEntry}`,
86
87
  crossOrigin: "anonymous"
87
- }, "remote-entry"));
88
+ }, remoteEntry.split(".")[0]));
88
89
  [
89
90
  ...targetModule.assets.js.sync
90
91
  ].forEach((file, index) => {
91
92
  scripts.push(/* @__PURE__ */ _jsx("script", {
93
+ async: true,
92
94
  src: `${publicPath}${file}`,
93
95
  crossOrigin: "anonymous"
94
- }, index));
96
+ }, `${file.split(".")[0]}_${index}`));
95
97
  });
96
98
  }
97
99
  return [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@module-federation/modern-js",
3
- "version": "0.0.0-next-20240530073428",
3
+ "version": "0.0.0-next-20240530085615",
4
4
  "files": [
5
5
  "dist/",
6
6
  "types.d.ts",
@@ -46,10 +46,10 @@
46
46
  "@modern-js/utils": "^2.49.2",
47
47
  "@modern-js/node-bundle-require": "^2.49.2",
48
48
  "node-fetch": "~3.3.0",
49
- "@module-federation/sdk": "0.0.0-next-20240530073428",
50
- "@module-federation/enhanced": "0.0.0-next-20240530073428",
51
- "@module-federation/node": "0.0.0-next-20240530073428",
52
- "@module-federation/dts-plugin": "0.0.0-next-20240530073428"
49
+ "@module-federation/sdk": "0.0.0-next-20240530085615",
50
+ "@module-federation/enhanced": "0.0.0-next-20240530085615",
51
+ "@module-federation/node": "0.0.0-next-20240530085615",
52
+ "@module-federation/dts-plugin": "0.0.0-next-20240530085615"
53
53
  },
54
54
  "devDependencies": {
55
55
  "@modern-js/app-tools": "^2.49.2",
@@ -57,7 +57,7 @@
57
57
  "@modern-js/runtime": "^2.49.2",
58
58
  "@modern-js/module-tools": "^2.35.0",
59
59
  "@modern-js/tsconfig": "^2.35.0",
60
- "@module-federation/manifest": "0.0.0-next-20240530073428"
60
+ "@module-federation/manifest": "0.0.0-next-20240530085615"
61
61
  },
62
62
  "peerDependencies": {
63
63
  "react": ">=17",