Skip to content
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

hmr stopped working after webpack refactor in v1.1.0 #1147

Open
3cp opened this issue Sep 7, 2019 · 8 comments
Open

hmr stopped working after webpack refactor in v1.1.0 #1147

3cp opened this issue Sep 7, 2019 · 8 comments

Comments

@3cp
Copy link
Member

3cp commented Sep 7, 2019

@Sayan751 please have a look on hmr. I tried to bring back some plugin from old run task, but could not make it work.

@3cp 3cp changed the title hmr stopped working about webpack refactor in v1.1.0 hmr stopped working after webpack refactor in v1.1.0 Sep 7, 2019
@Sayan751
Copy link
Member

Sayan751 commented Sep 8, 2019

@3cp On which skeleton you tried the HMR. I suspect that the problem might also exist even when CLI is not used. I will try to replicate the issue with the setup, you are facing problem with, without CLI.

I did a quick check and saw that the skeletons are not using the HotModuleReplacementPlugin from webpack. I used that with the navigation skeleton. Any changes in HTML are reflected via HMR w/o full reload, where any change in VM resulted in full reload. I tried to do the same with the minimum skeleton, the result was not the same, as neither changes were reflected.

As per my personal experience, the HMR in Aurelia works similar to the results found in the navigation skeleton. I need to dig deeper, but I suspect that it has nothing to do with the new refactoring. I need to verify this claim that with an earlier version of CLI though.

@3cp
Copy link
Member Author

3cp commented Sep 8, 2019

Thx. I only tried latest webpack skeleton, not the old one. I am not sure when was this stopped working.

@Sayan751
Copy link
Member

Sayan751 commented Sep 8, 2019

@3cp I mean with which combination you created the skeleton on which you tested the HMR.

BTW I have dug a bit, and I think this particular code is incorrectly binding the view with old context. And I suspect that this is the reason why the changes in VM is not reflected.

I still need to dig deeper.

@3cp
Copy link
Member Author

3cp commented Sep 8, 2019

I mean hmr is not working, code change triggered full reload, not hot module reload.

@3cp
Copy link
Member Author

3cp commented Sep 8, 2019

The old run task added a plugin for hmr mode. I tried that but it didn't change anything.

@xenoterracide
Copy link

hmm... with webpack on a app I created last week I'm not noticing any page content reloads https://github.com/xenoterracide/capacitor-android-issue-repro

@3cp
Copy link
Member Author

3cp commented Feb 11, 2020

I tried your repo, both npm start and au run worked for me with page reloads. But I don't know what's your command to run the android thing, no experience on that.

Let me know your system setup (os, browser...) if npm start didn't work for you.

@xenoterracide
Copy link

I suspect actually that I was noticing this while I was trying to reload on code that was failing in some way (like failing to compile) so not a real issue, nevermind.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants