简体   繁体   中英

React MUI custom select component on mobile throws error

Codesandbox link from mui doc

https://codesandbox.io/s/izm2c2?file=/demo.js inspect and try different dimension (phone, ipad or anything) by opening in new window.

I can't find way to resolve this error.

Error
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.

Thanks in advance!

The the problem seems to be with react 18>. Try downgrading to react 17< thats what fixed the issue for me.

You should post the issue on github as well

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM