module federation dependencies mis-used
Closed this issue · 4 comments
Describe the bug
module-ferderation-webpack example required rs-pack dependency
hi, i do not understand the issue.
rspack is used via the rspack plugin here - https://bit.cloud/frontend/module-federation/react/producer/~code/producer.bit-app.ts#l1
the dependency graph does not show packages, only components.
sorry about this misunderstanding, the producer example suppose to require webpack but instead it requires mf-rspack type
import { MfReact } from '@frontend/module-federation.react.apps-types.mf-rspack';
I don't know if this is the problem that resulted in
Could not load content for webpack://producer/remote-scope/react/producer/button.tsx (Fetch through target failed: Unsupported URL scheme; Fallback: HTTP error: status code 404, net::ERR_UNKNOWN_URL_SCHEME)
when i try to bit run it i found in debug panel source tab, with button.tsx was not being loaded
Hi, if you prefer to use webpack
instead, you can use the following import:
import { MfReact } from '@frontend/module-federation.react.apps-types.mf-webpack';
You don't need to change anything else. (I'm changing the import anyway to avoid future misunderstandings)
About the other error, I think it's common when working with webpack/rspack, it's just chrome not able to resolve the code.
Hi, if you prefer to use
webpack
instead, you can use the following import:import { MfReact } from '@frontend/module-federation.react.apps-types.mf-webpack';You don't need to change anything else. (I'm changing the import anyway to avoid future misunderstandings)
About the other error, I think it's common when working with webpack/rspack, it's just chrome not able to resolve the code.
Thanks I am closing this issue for now.