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
We have the following application structure: host_app: AngularDart. independent_app_1 : TS + react
entry: index.js independent_app_2 : TS + react
entry: index.js
The idea, is to use Module Federation to share common dependencies like react between TS independent apps.
The integration between host app and independent apps are done via web components.
The flow is the following: host_app injects to the page independent_app_1/index.js, then independent_app_1 injects independent_app_2/index.js. Each index.js defines web component to be used by other apps.
I configured Module Federation plugin to share react and react-dom. But when index.js are loaded, they each loads it's own react and react-dom.
Is there a way to share dependencies without having remoteEntry.js?
UPD:
I found that dependencies are not shared, if use custom chunks naming like:
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
We have the following application structure:
host_app: AngularDart.
independent_app_1 : TS + react
entry: index.js
independent_app_2 : TS + react
entry: index.js
The idea, is to use Module Federation to share common dependencies like react between TS independent apps.
The integration between host app and independent apps are done via web components.
The flow is the following:
host_app injects to the page independent_app_1/index.js, then independent_app_1 injects independent_app_2/index.js. Each index.js defines web component to be used by other apps.
I configured Module Federation plugin to share react and react-dom. But when index.js are loaded, they each loads it's own react and react-dom.
Is there a way to share dependencies without having remoteEntry.js?
UPD:
I found that dependencies are not shared, if use custom chunks naming like:
Beta Was this translation helpful? Give feedback.
All reactions