Skip to content

Federation on fixed publicPath #832

Answered by XiaofengXie16
scherler asked this question in Q&A
Discussion options

You must be logged in to vote

I would recommend to use this approach below . In your host, you can call the set public path method to your local path(with the correct port number)

https://webpack.js.org/concepts/module-federation/#offer-a-host-api-to-set-the-publicpath

You can also see the working code in this link below. I modified it based on your code.
https://github.com/XiaofengXie16/module-federation-example

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by ScriptedAlchemy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants