You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It should just work if you install a package in a separate terminal session. Without restarting.
If it doesn't work this is a bug and someone should look into it.
@reznord I think there is still some bug because manually reloading the tab didn't trigger a rebuild, it only worked after editing code and saving it, ideally WatchMissingNodeModulesPlugin should have triggered a rebuild.
I find this to be happening not for brand new installs, but for updates of existing node modules. Like if I run yarn upgrade package-x, I find I have to manually restart the dev server to get those changes to appear. Should that work out of the box as well? Thank you!
manually reloading the tab didn't trigger a rebuild
@supra28 I'm not sure how that is related to this. Manually reloading a tab will not trigger a rebuild. Because HMR will not be fired every time you refresh the tab. HRM looks for changes in JS/CSS files.
Reloading the tab doesn't fire HMR since no changes in JS/CSS are made.
@reznord Sorry that's not what I meant, what I meant was shouldn't WatchMissingNodeModulesPlugin already trigger a rebuild after installing a new package even if i didn't make any change to the js/css files?
If it worked I should see the new page after manually reloading because the build should contain the new package now. Not talking about HMR.
Activity
gaearon commentedon Jun 26, 2017
This used to work. Can you provide more details? Exact way to reproduce, which package you were installing, how it didn't work, etc.
miraage commentedon Jun 27, 2017
Kinda strange.
WatchMissingNodeModulesPluginworks like a charm for me in CRA-apps and my own webpack configurations.supra28 commentedon Jul 3, 2017
:O I thought that was normal.
@gaearon I always stop the server then install a package and start the server again. Is there a better way to do it?
gaearon commentedon Jul 3, 2017
It should just work if you install a package in a separate terminal session. Without restarting.
If it doesn't work this is a bug and someone should look into it.
gaearon commentedon Jul 3, 2017
Tagging as up for grabs: we need someone to try reproducing it, and report whether it is reproducible or not.
reznord commentedon Jul 3, 2017
@gaearon, I am not able to reproduce this issue.
These are the following steps what I've followed to test this issue:
yarn startqspackage (didn't stop the server)src/app.jsand tried to render the URL query parameters values.gaearon commentedon Jul 3, 2017
@reznord Thanks for trying!
@supra28 Can you verify if the same steps cause the issue for you? Or if you can suggest other steps that cause it, it would be helpful.
supra28 commentedon Jul 4, 2017
@reznord @gaearon I followed these steps:
and I did this:
reznord commentedon Jul 4, 2017
Yes, HMR works only when there is a change CSS/JS files.
In this case, it will work if you are making some changes in the JS file and save it. It will work perfectly without any errors.
supra28 commentedon Jul 4, 2017
@reznord I think there is still some bug because manually reloading the tab didn't trigger a rebuild, it only worked after editing code and saving it, ideally WatchMissingNodeModulesPlugin should have triggered a rebuild.
tnrich commentedon Jul 28, 2017
I find this to be happening not for brand new installs, but for updates of existing node modules. Like if I run yarn upgrade package-x, I find I have to manually restart the dev server to get those changes to appear. Should that work out of the box as well? Thank you!
gaearon commentedon Jul 28, 2017
That should work, but I don’t think we tested with Yarn. Maybe it only worked with npm.
reznord commentedon Jul 28, 2017
@supra28 I'm not sure how that is related to this. Manually reloading a tab will not trigger a rebuild. Because HMR will not be fired every time you refresh the tab. HRM looks for changes in JS/CSS files.
Reloading the tab doesn't fire HMR since no changes in JS/CSS are made.
tnrich commentedon Jul 28, 2017
@gaearon , rebundling on yarn upgrade is definitely not working with the following commands:
In terminal tab #1:
In terminal tab #2:
At the top of
yarn-upgrade-test/src/App.jsadd:in the browser console you'll now see:
In terminal tab #2 run:
in the browser console you'll still see:
instead of the expected
https://github.com/tnrich/semver-console
supra28 commentedon Jul 29, 2017
@reznord Sorry that's not what I meant, what I meant was shouldn't
WatchMissingNodeModulesPluginalready trigger a rebuild after installing a new package even if i didn't make any change to the js/css files?If it worked I should see the new page after manually reloading because the build should contain the new package now. Not talking about HMR.
gaearon commentedon Jan 8, 2018
Closing in favor of #2956 which is more focused.