Skip to content

Commit 7bea6b5

Browse files
Enable async startup for rspack interop apps
1 parent 3107582 commit 7bea6b5

File tree

6 files changed

+15
-6
lines changed

6 files changed

+15
-6
lines changed

rspack-webpack-interop/app-01/rspack.config.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,9 @@ module.exports = {
5757
'./SideNav': './src/SideNav',
5858
'./Page': './src/Page',
5959
},
60+
experiments: {
61+
asyncStartup: true,
62+
},
6063
shared: {
6164
...deps,
6265
'@material-ui/core': {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
console.log(__webpack_require__.federation);
2-
import('./bootstrap');
2+
import './bootstrap';

rspack-webpack-interop/app-01/webpack.config.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,9 @@ module.exports = {
5858
'./SideNav': './src/SideNav',
5959
'./Page': './src/Page',
6060
},
61+
experiments: {
62+
asyncStartup: true,
63+
},
6164
shared: {
6265
...deps,
6366
'@material-ui/core': {

rspack-webpack-interop/app-02/package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@
1313
"serve": "^14.2.1",
1414
"webpack": "5.101.0",
1515
"webpack-cli": "^5.1.4",
16-
"@rspack/core": "1.4.11",
17-
"@rspack/cli": "1.4.11",
18-
"@rspack/dev-server": "1.1.3"
16+
"@rspack/core": "npm:@rspack-canary/[email protected]",
17+
"@rspack/cli": "npm:@rspack-canary/[email protected]",
18+
"@rspack/dev-server": "npm:@rspack-canary/[email protected]"
1919
},
2020
"scripts": {
2121
"build": "cross-env NODE_ENV=production rspack build --mode production",
@@ -27,4 +27,4 @@
2727
"serve": "serve dist -p 3002",
2828
"clean": "rm -rf dist"
2929
}
30-
}
30+
}

rspack-webpack-interop/app-02/rspack.config.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,9 @@ module.exports = {
5353
'./Dialog': './src/Dialog',
5454
'./Tabs': './src/Tabs',
5555
},
56+
experiments: {
57+
asyncStartup: true,
58+
},
5659
shared: {
5760
...deps,
5861
'@material-ui/core': {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
import('./bootstrap');
1+
import './bootstrap';

0 commit comments

Comments
 (0)