question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Gatsby doesn't work with React 17 RC (Error: React-Hot-Loader: AppContainer should be patched)

See original GitHub issue
  1. Update react and react-dom to 17.0.0-rc.1
  2. Update gatsby to latest
  3. Run yarn dev

This is the result:

Screenshot 2020-09-21 at 17 45 55

While there’s ongoing work to make Fast Refresh the default for compatible setups, in the meantime, can we figure out how to fix this error?

I’m guessing that what needs to happen is for https://github.com/hot-loader/react-dom/issues/41 to be solved by publishing a patched package. This is likely little work, but requires access to that package (cc @theKashey). I could do this myself if I had the instructions.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:13 (4 by maintainers)

github_iconTop GitHub Comments

17reactions
gaearoncommented, Sep 22, 2020

Concretely, if you’re running this error, the fix is to run npm update.

If this didn’t help, delete your lockfile (yarn.lock or package-lock.json) and re-run your package manager.

5reactions
theKasheycommented, Sep 22, 2020

hot-loader/react-dom(17.0.0-rc.2) and react-hot-loader(4.13.0) were updated and should not cause the issue anymore.

Read more comments on GitHub >

github_iconTop Results From Across the Web

React-hot-loader: react- -dom patch is not detected
React -hot-loader: react- -dom patch is not detected. React 16.6+ features may not work. However, when I look into the source code,...
Read more >
Leko / れこ on Twitter: "Reactを17に上げたら"React-Hot-Loader ...
Gatsby doesn't work with React 17 RC (Error: React-Hot-Loader: AppContainer should be patched) ·... Update react and react-dom to 17.0.0-rc.1 Update gatsby ......
Read more >
fixing react-hot-loader in gatsby - Brad Garropy
To fix this, first install the latest version of @hot-loader/react-dom . Then modify the webpack configuration in the gatsby-node. js file. The ...
Read more >
Error: React-Hot-Loader: AppContainer should be patched
Gatsby doesn't work with React 17 RC (Error: React-Hot-Loader: AppContainer should be patched) · Issue #26979 · gatsbyjs/gatsby.
Read more >
can't resolve 'react-dom/client' - You.com | The AI Search ...
Issue is react-dom is not installed, when you hit npm -v react-dom , it gives you the version of npm not react-dom version,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found