Skip to content

Commit 3ac3fc8

Browse files
authored
fix(rsbuild-plugin): failed to load remote modules with server.base (#3102)
1 parent b29c403 commit 3ac3fc8

File tree

10 files changed

+421
-312
lines changed

10 files changed

+421
-312
lines changed

apps/router-demo/router-host-2000/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
},
1919
"devDependencies": {
2020
"@module-federation/rsbuild-plugin": "workspace:*",
21-
"@rsbuild/core": "^1.0.7",
21+
"@rsbuild/core": "^1.0.16",
2222
"@rsbuild/plugin-react": "^1.0.3",
2323
"@types/react": "^18.2.79",
2424
"@types/react-dom": "^18.3.0",

apps/router-demo/router-host-v5-2200/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
},
2020
"devDependencies": {
2121
"@module-federation/rsbuild-plugin": "workspace:*",
22-
"@rsbuild/core": "^1.0.7",
22+
"@rsbuild/core": "^1.0.16",
2323
"@rsbuild/plugin-react": "^1.0.3",
2424
"@types/react": "^18.2.79",
2525
"@types/react-dom": "^18.3.0",

apps/router-demo/router-host-vue3-2100/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
},
1616
"devDependencies": {
1717
"@module-federation/rsbuild-plugin": "workspace:*",
18-
"@rsbuild/core": "^1.0.7",
18+
"@rsbuild/core": "^1.0.16",
1919
"@rsbuild/plugin-vue": "^1.0.1",
2020
"tailwindcss": "^3.4.3",
2121
"typescript": "^5.4.2"

apps/router-demo/router-remote1-2001/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
},
1919
"devDependencies": {
2020
"@ant-design/cssinjs": "^1.20.0",
21-
"@rsbuild/core": "^1.0.7",
21+
"@rsbuild/core": "^1.0.16",
2222
"@rsbuild/plugin-react": "^1.0.3",
2323
"@rsbuild/shared": "^0.7.10",
2424
"@types/react": "^18.2.79",

apps/router-demo/router-remote2-2002/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"react-router-dom": "6.24.1"
1818
},
1919
"devDependencies": {
20-
"@rsbuild/core": "^1.0.7",
20+
"@rsbuild/core": "^1.0.16",
2121
"@rsbuild/plugin-react": "^1.0.3",
2222
"@types/react": "^18.2.79",
2323
"@types/react-dom": "^18.3.0",

apps/router-demo/router-remote3-2003/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"vue-router": "^4.3.2"
1515
},
1616
"devDependencies": {
17-
"@rsbuild/core": "^1.0.7",
17+
"@rsbuild/core": "^1.0.16",
1818
"@rsbuild/plugin-vue": "^1.0.1",
1919
"@vue/tsconfig": "^0.5.1",
2020
"tailwindcss": "^3.4.3",

apps/router-demo/router-remote4-2004/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"react-router-dom": "6.24.1"
1818
},
1919
"devDependencies": {
20-
"@rsbuild/core": "^1.0.7",
20+
"@rsbuild/core": "^1.0.16",
2121
"@rsbuild/plugin-react": "^1.0.3",
2222
"@types/react": "^18.2.79",
2323
"@types/react-dom": "^18.3.0",

packages/rsbuild-plugin/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
"@module-federation/sdk": "workspace:*"
3636
},
3737
"devDependencies": {
38-
"@rsbuild/core": "1.x"
38+
"@rsbuild/core": "^1.0.16"
3939
},
4040
"peerDependencies": {
4141
"@rsbuild/core": "1.x",

packages/rsbuild-plugin/src/cli/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ export const pluginModuleFederation = (
6060
const originalConfig = api.getRsbuildConfig('original');
6161
if (
6262
originalConfig.dev?.assetPrefix === undefined &&
63-
config.dev.assetPrefix === DEFAULT_ASSET_PREFIX
63+
config.dev.assetPrefix === config.server?.base
6464
) {
6565
config.dev.assetPrefix = true;
6666
}

0 commit comments

Comments
 (0)