pwa-studio
pwa-studio copied to clipboard
[bug]: Webpack hot reload broken
Describe the bug
Changing e.g. CSS styles will perform a full reload on the page in dev mode.
To reproduce
Steps to reproduce the behavior:
- yarn watch
- Go to the page
- Add background: black; to root element in @magento/venia-ui/lib/components/Header/header.module.css
- Page reloads
Expected behavior
Whenever possible Webpack HMR (Hot Module Replacement) should update the page in dev mode without reloading the page.
Possible solutions
Temporary fix is to remove the server config in webpack.config.js that was added in https://github.com/magento/pwa-studio/commit/1977f38305ff6c0e2b23a9da7beb0b2f69758bed.
Please complete the following device information:
- Device: Windows 11
- Browser: Chrome
- Browser Version: 97.0.4692.71
Please let us know what packages this bug is in regards to:
- [X]
venia-concept
- [ ]
venia-ui
- [ ]
pwa-buildpack
- [ ]
peregrine
- [ ]
pwa-devdocs
- [ ]
upward-js
- [ ]
upward-spec
- [ ]
create-pwa
Hi @Risto-T. Thank you for your report. To speed up processing of this issue, make sure that you provided sufficient information.
Add a comment to assign the issue: @magento I am working on this
- Join Magento Community Engineering Slack and ask your questions in #github channel.
@magento export issue to JIRA project PWA as Bug
:white_check_mark: Jira issue https://jira.corp.magento.com/browse/PWA-2530 is successfully created for this GitHub issue.
Hello! Any progress with this issue? I tried some different things, but the hot reload doesn't work. Maybe any workaround meanwhile the issue is being resolved. Thanks!
Updated stylesheet as mentioned in issue description, and found WDS is running hot reloading as expected .
@Risto-T , If We have missed any step kindly let us know.
Below are the screen recordings -
https://github.com/magento/pwa-studio/assets/127731581/04527e6a-2df3-4551-9321-113582dac9de
https://github.com/magento/pwa-studio/assets/127731581/05c8c671-e52e-409b-8b27-be377928ca55
closing the ticket since no updated from last 2 week, please feel free to reopenn in case issue still persist