Since a couple of months every old and new project reloads the whole page instead of specific components.
I use single file components and no matter what I change - it's a full page refresh every time.
Is this intended?
Of course not, why should we disable HNR on purpose?
What's confusing me is that you say that happens for old projects as well. Otherwise I would have thought we have a problem with the new webpack-dev-server setup (which works well for me).
Did you change anything about the environment of your project folders? HNR sometimes has problems with special characters in paths or folders that are controlled by other apps, i.e. Dropbox, Vagrant... In the latter case, using the poll option for webpacks watcher
hmm no. Brand new project, regular file system on a mac...
Is there a project I can clone where you can verify Hot Module Reloading works? Then I can nail down if it's my project setup or something with my mac.
oh, and have a save and fun new years 馃嵕 馃殌 馃槉
@LinusBorg based on this comment I tried commenting out line 41 in build/dev-server.js and HMR is working again 馃帀
hotMiddleware.publish({ action: 'reload' })
Not sure what that means exactly I just tried what I found during research. Can you make any sense of that?
Ah, yes.
That part of the devservrr was responsible for reloading the page when index.html changes.
However. the html-webpack-plugin we use to process index.html doesn't play nice with webpack >=3 in that regard, so we had to remove that code when we moved to webpack 3 a while back.
I assume you moved to webpack 3 on your own...
ah ok. Weird 馃. No I haven't updated myself in that particular project, but in other ones. Anyway:
Can I remove that line without damage to the setup?
Yes. As I said we removed it as well.
Most helpful comment
@LinusBorg based on this comment I tried commenting out line 41 in
build/dev-server.jsand HMR is working again 馃帀Not sure what that means exactly I just tried what I found during research. Can you make any sense of that?