Wonderfully explain David!
Funny! I encountered the same re-rendering issue while making a fetch call outside of a useEffect hook recently, I went ahead throwing the memo function in the component, but that didn't solve the re-rendering issue.
Then after some time, I noticed the fetch call was outside a useEffect hook 😂, what a bug I spent some time trying to figure out what was wrong.
Thanks for sharing!