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.

react-select with webpack dev server and hot reload crashes

See original GitHub issue

I am not able to reproduce this other than locally 😕

I get this error whenever I click on a react-select element:

Uncaught Invariant Violation: Maximum update depth exceeded. This can happen when a component repeatedly calls setState inside componentWillUpdate or componentDidUpdate. React limits the number of nested updates to prevent infinite loops.
    at invariant (http://localhost:8080/public/app.js:181388:15)
    at scheduleWork (http://localhost:8080/public/app.js:201249:5)
    at Object.enqueueSetState (http://localhost:8080/public/app.js:192502:5)
    at MenuPlacer../node_modules/react/cjs/react.development.js.Component.setState (http://localhost:8080/public/app.js:229658:16)
    at Object.ref (http://localhost:8080/public/app.js:212984:13)
    at ref (http://localhost:8080/public/app.js:172916:31)
    at commitAttachRef (http://localhost:8080/public/app.js:198828:7)
    at commitAllLifeCycles (http://localhost:8080/public/app.js:200074:7)
    at HTMLUnknownElement.callCallback (http://localhost:8080/public/app.js:181482:14)
    at Object.invokeGuardedCallbackDev (http://localhost:8080/public/app.js:181532:16)

When building with webpack, this error goes away.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
olemartincommented, Jun 17, 2020

Hi @bladey. No, when running with hot reload the error is still present. I have to build locally in order to get it working, and that makes the development roundtrip a bit long.

0reactions
Armer7commented, Aug 26, 2021

@Armer7 Can you try react-select@5.0.0-beta.0? We’ve removed AutosizeInput completely in v5 so it’s likely that will fix the issue.

Ok. I try it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

react app crashes on refresh [webpack , REACT ]
Tell Webpack Dev Server to redirect all server requests to /index.html . There are just two properties in your webpack config you need...
Read more >
webpack crashes node frequently during development - GitLab
Node (running webpack) has been crashing a lot for me today, apparently due to running out of memory. I'm not doing anything beyond...
Read more >
How I solved and debugged my Webpack issue through trial ...
When webpack bundles your source code, it can become difficult to track down errors and warnings to their original location.
Read more >
React v18.0 – React Blog
In this post, we'll give an overview of what's new in React 18, and what it means for the future. Our latest major...
Read more >
Production | webpack
In development, we want strong source mapping and a localhost server with live reloading or hot module replacement. In production, our goals shift...
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