|
| 1 | +# v0.1 Release |
| 2 | + |
| 3 | +> April 3, 2024 |
| 4 | +
|
| 5 | +We have recently released the **v0.1** version of **[Module Federation Enhanced](https://github.com/module-federation/universe)** (You can simply think of it as the early version of Module Federation 2.0.)! |
| 6 | + |
| 7 | +`Module Federation Enhanced` differs from the `Module Federation` built into `Webpack5` by providing not only the core features of module export, loading, and dependency sharing but also additional dynamic type hinting, `Manifest`, `Federation Runtime`, and `Runtime Plugin`. These features make `Module Federation` more suitable for use as a micro-frontend architecture in large-scale `Web` applications. |
| 8 | + |
| 9 | +### 🔥 Features |
| 10 | + |
| 11 | +`Module Federation` comes with the following features: |
| 12 | + |
| 13 | +- **New Documentation**: `Module Federation` has launched a [brand-new documentation](https://module-federation.io/), which can help you better understand and utilize `Module Federation`. |
| 14 | + |
| 15 | +- **Dynamic Type Hinting**: `Module Federation` uses dynamic runtime, which previously did not support `TypeScript` type hinting. This significantly impacted the stability and maintainability of projects. Therefore, `Module Federation` now supports out-of-the-box type exports and dynamic type loading capabilities, as well as hot type updating, providing an experience akin to loading local `NPM` modules. |
| 16 | + |
| 17 | +- **Manifest**: In the past, `Module Federation` primarily used `remoteEntry.js` as the entry point for `Module Federation` modules. Remote modules could not store more original information, such as type files, exposes, remotes, etc. We now support setting `remote` to `mf-manifest.json`, which enables more advanced capabilities: `type hinting`, `resource preloading`, `visualized dependency relationships`, `shared dependency analysis`, `integration with deployment platforms`, and `service discovery`. |
| 18 | + |
| 19 | +- **Federation Runtime**: `Federation Runtime` is an independent software development kit (SDK) that addresses compatibility issues with `Module Federation` across different build tools. In the early stages, the implementation of `Module Federation` was tightly coupled with `Webpack 5`, making it difficult for other build tools to support and leading to poor maintainability. By treating `Federation Runtime` as a separate component, the new versions of `Webpack` and `Rspack`, as well as other build tools, can more easily implement and maintain `Module Federation` features, enhancing the flexibility and efficiency of module loading and dependency sharing. |
| 20 | + |
| 21 | +- **Rspack**: The `Module Federation` in Rspack is based on `Federation Runtime`, thus enjoying all the additional capabilities of `Module Federation Enhance`. Moreover, due to the partitioned architecture concept of `Module Federation`, you can progressively migrate your large projects to `Rspack` through `Module Federation`. |
| 22 | + |
| 23 | +### 💡 Next Steps |
| 24 | + |
| 25 | +`Module Federation Enhanced` is still in rapid iteration and plans to introduce more powerful new features. |
| 26 | + |
| 27 | +For example, we are developing the **Module Federation Chrome Devtool**, a user-friendly `Module Federation` debugging and proxy tool that can directly proxy online project `Module Federation` modules to local and enable real-time hot updates. It provides a visual dependency graph that allows you to see the `Module Federation` dependency relationships and `Shared` settings. |
| 28 | + |
| 29 | +At the same time, we will offer more framework-level capabilities, such as: `Modern.js SSR`, `React Server Component`, `Router`, `Web Component`, `cross-frame`. |
| 30 | + |
| 31 | +### 🙏 Acknowledgements |
| 32 | + |
| 33 | +The release of `Module Federation Enhanced` version `0.1` would not have been possible without the feedback and suggestions from the `Module Federation` community and the efforts of contributors to the [`Universe`](https://github.com/module-federation/universe) repository. |
0 commit comments