React-static: Hot reload not working.

Created on 1 Sep 2018  路  3Comments  路  Source: react-static/react-static

Bug

Environment

  1. react-static -v: 5.9.7
  2. node -v: 8.11.3
  3. yarn --version or npm -v: yarn 1.9.4
  4. Operating system: Windows 10 x64
  5. Browser and version (if relevant): Google Chrome 68.0.3440.106 (Official Build) (64-bit)

Steps to Reproduce the problem

Base your steps off of any freshly installed react-static template!

  1. react-static create
  2. Chose the Netlify CMS template
  3. yarn start

Expected Behavior

Hot reloading of components should be working.

I see in the console that HMR is connected, but it doesn't pick up the changes =(

[HMR] Waiting for update signal from WDS...
React-Static data hot-loader websocket connected. Listening for data changes...

Most helpful comment

Ok, changing the .babelrc file to the following fixes the issue. If it's such an easy fix why don't you push a fix?

{
  "extends": "react-static/.babelrc",
  "plugins": [
    "react-hot-loader/babel"
  ]
}

All 3 comments

Hi, I have the same issue, however since v6 is cooking, I think we can live with the issue, then migrate to 6.

Ok, changing the .babelrc file to the following fixes the issue. If it's such an easy fix why don't you push a fix?

{
  "extends": "react-static/.babelrc",
  "plugins": [
    "react-hot-loader/babel"
  ]
}
Was this page helpful?
0 / 5 - 0 ratings