Ask questionsBug: Warning: unstable_flushDiscreteUpdates: Cannot flush updates when React is already rendering if debugger present
If a debugger is present in the main body of a functional component then on hitting the debugger and proceeding from there an unstable_flushDiscreteUpdates warning is thrown.
React version: ^16.13.1
debugger right above the React.useEffect() in the DiscoverBooksScreen Componentdebugger break point and resume execution of codeLink to code example: https://github.com/kentcdodds/bookshelf
unstable_flushDiscreteUpdates warning is thrown in the console
unstable_flushDiscreteUpdates warning should not be thrown in the console

Answer
questions
kentcdodds
And it's not just something weird about the bookshelf app as @SangeetAgarwal notes:
I was able to reproduce this issue in an app written a couple of years back that used class components too
https://github.com/kentcdodds/bookshelf/issues/113#issuecomment-720100770
Related questions