Declare MF 2.0 config with 4 feature exposes and React singleton

This commit is contained in:
2026-04-14 22:37:07 +03:00
parent 2bdfde43f6
commit 5881f9ed72
+15
View File
@@ -0,0 +1,15 @@
import { createModuleFederationConfig } from "@module-federation/modern-js";
export default createModuleFederationConfig({
name: "aeroflot_flights",
exposes: {
"./OnlineBoard": "./src/mf/expose/OnlineBoard.tsx",
"./Schedule": "./src/mf/expose/Schedule.tsx",
"./FlightsMap": "./src/mf/expose/FlightsMap.tsx",
"./PopularRequests": "./src/mf/expose/PopularRequests.tsx",
},
shared: {
react: { singleton: true, requiredVersion: "^18.2.0" },
"react-dom": { singleton: true, requiredVersion: "^18.2.0" },
},
});