-
Notifications
You must be signed in to change notification settings - Fork 253
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dev mode in the host #410
Comments
@norman-ags Did you find a solution to this as I'm also having the same issue. One thing I noticed is, it is working fine in localhost but not in 127.0.0.1. |
@mjangir @norman-ags did you already find a solution? |
No. ATM it's fine for us to run all in preview. For dev mode, we run each microfrontend independently. |
this is weird. 127.0.0.1 is failing, localhost is working. |
I tried the latest version v1.2.3 and indeed encountered the issue. It works fine when I use localhost, but there are problems when I switch to 127.0.0.1. |
Tried it out and it's strange that when not using |
Dependent on this PR, both 127.0.0.1 and localhost can be used normally after configuring |
For some reason I had |
It would be immensely beneficial if we could resolve this issue, enabling real-time updates to be visible from the host when working with the MF architecture. |
That's exactly also what I want. The best I've been able to get is to have the vite build and preview in one command, to enable module federation, with this: "preview:watch": "concurrently \"vite preview --port 4001 -l silent\" \"vite build --watch\"" But it does not have HMR, nor does it can have. So there's where having the module federation vite plugin should allow to create the remoteEntry.js with dev mode would be really helpful. This way we could have HMR with VITE when using MF. Hopefully some day we will have it as an option to enable |
Somtimes, the preview command finishes ealier than the build watch command which fails the ouput of the preview command. Is there a way make the preview command run only after the build watch command? |
Any temporary solution or workaround? I'm going through the same thing 🙁 |
Versions
Hi! I'm trying to run this demo of Jack in dev mode: https://youtu.be/t-nchkL9yIg but it failed to work.
The readme of this project says:
Only the Host side supports dev mode, the Remote side requires the RemoteEntry.js package to be generated using vite build. This is because Vite Dev mode is Bundleless and you can use vite build --watch to achieve a hot update effect
.Reproduction
This repo from Jack
https://github.com/jherr/vite-mod-fed
Steps to reproduce
In the host:
dev
In the remote:
What is Expected?
Should not break the host app and the microfrontend should load.
What is actually happening?
From what I understand in the README, dev mode should work fine in the host, but I'm getting an error in the browser console:
And the whole app breaks.
The text was updated successfully, but these errors were encountered: