react-redux-starter-kit icon indicating copy to clipboard operation
react-redux-starter-kit copied to clipboard

HMR no workie for async reducer (counter)

Open matgessel opened this issue 8 years ago • 0 comments

Repro:

  1. start with vanilla clone of project
  2. change /project.config.publicPath to 'http://localhost:3000/' (may be a firewall issue or just a Mac thing)
  3. npm run start
  4. browse to http://localhost:3000/counter
  5. in src/routes/Counter/modules/counter.js, change COUNTER_INCREMENT (e.g. state + action.payload + 1)
  6. click "Increment" button Expected: HMR reloads; Counter increments by 2 Actual: HMR appears to reload, but Counter continues with original logic, incrementing by 1. [HMR] bundle rebuilding client.js?207a:207 [HMR] bundle rebuilt in 426ms process-update.js:27 [HMR] Checking for updates on the server... process-update.js:100 [HMR] Updated modules: process-update.js:102 [HMR] - ./src/routes/Counter/modules/counter.js process-update.js:102 [HMR] - ./src/routes/Counter/containers/CounterContainer.js process-update.js:102 [HMR] - ./src/routes/Counter/index.js process-update.js:102 [HMR] - ./src/routes/index.js process-update.js:107 [HMR] App is up to date.
  • HMR does work for UI, e.g. changing button label in Counter.js.
  • this issue was not caused by the Webpack 2 update; this test case also fails for the April 9 commit https://github.com/davezuko/react-redux-starter-kit/commit/1a4a71b182782bc12109f98106d3a65519003447.

matgessel avatar May 26 '17 04:05 matgessel