@module-federation/modern-js 0.0.0-next-20250407023255 → 0.0.0-next-20250407031542
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/cjs/cli/index.js +1 -1
- package/dist/cjs/cli/ssrPlugin.js +1 -1
- package/dist/esm/cli/index.js +1 -1
- package/dist/esm/cli/ssrPlugin.js +2 -1
- package/dist/esm-node/cli/index.js +1 -1
- package/dist/esm-node/cli/ssrPlugin.js +1 -1
- package/dist/types/types/index.d.ts +1 -1
- package/package.json +7 -7
package/dist/cjs/cli/index.js
CHANGED
|
@@ -38,7 +38,7 @@ const moduleFederationPlugin = (userConfig = {}) => {
|
|
|
38
38
|
distOutputDir: "",
|
|
39
39
|
originPluginOptions: userConfig,
|
|
40
40
|
remoteIpStrategy: userConfig === null || userConfig === void 0 ? void 0 : userConfig.remoteIpStrategy,
|
|
41
|
-
userConfig
|
|
41
|
+
userConfig: userConfig || {}
|
|
42
42
|
};
|
|
43
43
|
return {
|
|
44
44
|
name: "@modern-js/plugin-module-federation",
|
|
@@ -78,7 +78,7 @@ const mfSSRRsbuildPlugin = (pluginOptions) => {
|
|
|
78
78
|
if (ssrEnv !== utils.environment.name) {
|
|
79
79
|
return config;
|
|
80
80
|
}
|
|
81
|
-
const userSSRConfig = pluginOptions.userConfig.ssr
|
|
81
|
+
const userSSRConfig = pluginOptions.userConfig.ssr ? typeof pluginOptions.userConfig.ssr === "object" ? pluginOptions.userConfig.ssr : {} : {};
|
|
82
82
|
config.output.publicPath = `${config.output.publicPath}${userSSRConfig.distOutputDir || import_path.default.relative(csrOutputPath, ssrOutputPath)}/`;
|
|
83
83
|
return config;
|
|
84
84
|
};
|
package/dist/esm/cli/index.js
CHANGED
|
@@ -16,7 +16,7 @@ var moduleFederationPlugin = function() {
|
|
|
16
16
|
distOutputDir: "",
|
|
17
17
|
originPluginOptions: userConfig,
|
|
18
18
|
remoteIpStrategy: userConfig === null || userConfig === void 0 ? void 0 : userConfig.remoteIpStrategy,
|
|
19
|
-
userConfig
|
|
19
|
+
userConfig: userConfig || {}
|
|
20
20
|
};
|
|
21
21
|
return {
|
|
22
22
|
name: "@modern-js/plugin-module-federation",
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { _ as _async_to_generator } from "@swc/helpers/_/_async_to_generator";
|
|
2
|
+
import { _ as _type_of } from "@swc/helpers/_/_type_of";
|
|
2
3
|
import { _ as _ts_generator } from "@swc/helpers/_/_ts_generator";
|
|
3
4
|
import path from "path";
|
|
4
5
|
import { fs } from "@modern-js/utils";
|
|
@@ -45,7 +46,7 @@ var mfSSRRsbuildPlugin = function(pluginOptions) {
|
|
|
45
46
|
if (ssrEnv !== utils.environment.name) {
|
|
46
47
|
return config;
|
|
47
48
|
}
|
|
48
|
-
var userSSRConfig = pluginOptions.userConfig.ssr
|
|
49
|
+
var userSSRConfig = pluginOptions.userConfig.ssr ? _type_of(pluginOptions.userConfig.ssr) === "object" ? pluginOptions.userConfig.ssr : {} : {};
|
|
49
50
|
config.output.publicPath = "".concat(config.output.publicPath).concat(userSSRConfig.distOutputDir || path.relative(csrOutputPath, ssrOutputPath), "/");
|
|
50
51
|
return config;
|
|
51
52
|
};
|
|
@@ -12,7 +12,7 @@ const moduleFederationPlugin = (userConfig = {}) => {
|
|
|
12
12
|
distOutputDir: "",
|
|
13
13
|
originPluginOptions: userConfig,
|
|
14
14
|
remoteIpStrategy: userConfig === null || userConfig === void 0 ? void 0 : userConfig.remoteIpStrategy,
|
|
15
|
-
userConfig
|
|
15
|
+
userConfig: userConfig || {}
|
|
16
16
|
};
|
|
17
17
|
return {
|
|
18
18
|
name: "@modern-js/plugin-module-federation",
|
|
@@ -42,7 +42,7 @@ const mfSSRRsbuildPlugin = (pluginOptions) => {
|
|
|
42
42
|
if (ssrEnv !== utils.environment.name) {
|
|
43
43
|
return config;
|
|
44
44
|
}
|
|
45
|
-
const userSSRConfig = pluginOptions.userConfig.ssr
|
|
45
|
+
const userSSRConfig = pluginOptions.userConfig.ssr ? typeof pluginOptions.userConfig.ssr === "object" ? pluginOptions.userConfig.ssr : {} : {};
|
|
46
46
|
config.output.publicPath = `${config.output.publicPath}${userSSRConfig.distOutputDir || path.relative(csrOutputPath, ssrOutputPath)}/`;
|
|
47
47
|
return config;
|
|
48
48
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@module-federation/modern-js",
|
|
3
|
-
"version": "0.0.0-next-
|
|
3
|
+
"version": "0.0.0-next-20250407031542",
|
|
4
4
|
"files": [
|
|
5
5
|
"dist/",
|
|
6
6
|
"types.d.ts",
|
|
@@ -89,11 +89,11 @@
|
|
|
89
89
|
"@swc/helpers": "0.5.13",
|
|
90
90
|
"node-fetch": "~3.3.0",
|
|
91
91
|
"react-error-boundary": "4.1.2",
|
|
92
|
-
"@module-federation/rsbuild-plugin": "0.0.0-next-
|
|
93
|
-
"@module-federation/enhanced": "0.0.0-next-
|
|
94
|
-
"@module-federation/node": "0.0.0-next-
|
|
95
|
-
"@module-federation/sdk": "0.0.0-next-
|
|
96
|
-
"@module-federation/cli": "0.0.0-next-
|
|
92
|
+
"@module-federation/rsbuild-plugin": "0.0.0-next-20250407031542",
|
|
93
|
+
"@module-federation/enhanced": "0.0.0-next-20250407031542",
|
|
94
|
+
"@module-federation/node": "0.0.0-next-20250407031542",
|
|
95
|
+
"@module-federation/sdk": "0.0.0-next-20250407031542",
|
|
96
|
+
"@module-federation/cli": "0.0.0-next-20250407031542"
|
|
97
97
|
},
|
|
98
98
|
"devDependencies": {
|
|
99
99
|
"@rsbuild/core": "1.2.8",
|
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
"@modern-js/module-tools": "2.65.1",
|
|
103
103
|
"@modern-js/runtime": "2.65.1",
|
|
104
104
|
"@modern-js/tsconfig": "2.65.1",
|
|
105
|
-
"@module-federation/manifest": "0.0.0-next-
|
|
105
|
+
"@module-federation/manifest": "0.0.0-next-20250407031542"
|
|
106
106
|
},
|
|
107
107
|
"peerDependencies": {
|
|
108
108
|
"react": ">=17",
|