You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -85,20 +86,100 @@ In the above example we added a new `format: 'mf'` , which will help you add an
85
86
86
87
However, if you want this Rslib Module to consume other producers at the same time, do not use the build configuration `remote` parameter, because in other formats, this may cause errors, please refer to the example below using the Module Federation runtime
87
88
89
+
## Develop Module Federation remote module
90
+
91
+
Rslib support use `storybook` to develop Module Federation Rslib module
92
+
93
+
#### 1. install storybook and rsbuild storybook addon
There you go, start Storybook with `npx storybook`.
175
+
88
176
## Consume other Module Federation modules
89
177
90
178
Because there are multiple formats in Rslib, if you configure the `remote` parameter to consume other modules during construction, it may not work properly in all formats. It is recommended to access through the [Module Federation Runtime](https://module-federation.io/guide/basic/runtime.html)
Then consume other Module Federation modules at runtime, for example
104
185
@@ -156,3 +237,5 @@ pluginModuleFederation({
156
237
-`mf-host`: Rsbuild App Consumer
157
238
-`mf-react-component`: Rslib Module, which is both a producer and a consumer, provides the module to the `mf-host` as a producer, and consumes the `mf-remote`
0 commit comments