CSS hot reloading does not work in v6
See original GitHub issueAre you reporting a bug?
Yes.
Environment
react-static -v
: 6.0.0-beta.21node -v
: v10.11.0yarn --version or npm -v
: 1.10.1- Operating system: macOS
Steps to Reproduce the problem
- npm i -g react-static@6.0.0-beta.21
- react-static create
- choose basic
- yarn start
- modify app.css
Expected Behavior
CSS should hot reload, but it doesn’t
I’ve been using react-static@6 beta since 6.0.0-beta.14 and css hot reloading never worked for me.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:17 (12 by maintainers)
Top Results From Across the Web
React router hot-reload not working - Stack Overflow
This as well happens when I make some changes to the item page and hot reloading is rerendering it. It looks like all...
Read more >Webpack Hot Reload not working in react Storybook 6.0-rc.9
Describe the bug After changing a story the page reloads and I get following message in the browser console [HMR] The following modules ......
Read more >Hot Reload in ElectronJS - GeeksforGeeks
This tutorial will demonstrate how to implement hot reloading in Electron using electron-reload npm package and electron-reloader npm package.
Read more >Server Rendering with React and React Router - ui.dev
In this comprehensive, up-to-date guide, you'll learn how, why, and when to add server rendering to a React and React Router application.
Read more >Babel Plugin: React CSS Modules - npm
Start using @dr.pogodin/babel-plugin-react-css-modules in your project by running ... If you don't know what is Hot Module Reloading (HMR), ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@SleeplessByte tested on both windows 10 and Ubuntu 18 with both blank and basic installation. Changing the CSS doesn’t result in any changes until you refresh your browser.
Works fine when using “create react app” so nothing to do with the set up I’m using 😃 Care to share your configuration?
Should I create a new bug report? or does someone want to reopen this one?
I encountered this on a vanilla project after adding only the
react-static-plugin-stylus
plugin.HMR didn’t work for my Stylus stylesheets.
My work-around is below:
This will reload the transpiled CSS on all code changes. I’m sure there is a better way to do things but I’m not familiar with the HMR life-cycle and API.
Hope this helps someone.