use-reducer-async
use-reducer-async copied to clipboard
Why a different AbortController logic in 2.1.1?
Hi Daishi Kato! Thanks for this handy hook :)
I'm diving into the code, and I'm struggling to understand the reasoning behind the modifications you did to the AbortController logic in 2.1.1 (commit f335dda38a4a336fc709c7fc88558788c6eda8d8) . I read in the changelog that they are related to some compatibility with React 18, can you be more explicit about that? It feels like there would be no need of an additional state variable for the AbortController, but obviously I am missing something as that was indeed the case before.
Thanks for any insights!
#35 description might help. It didn't work with strict effect.
For more information: https://react.dev/reference/react/StrictMode#fixing-bugs-found-by-re-running-effects-in-development