Your explainations are clear and accessible.
I probably found a typo in your custom hook useFetchData inside the useEffect deps. You wrote [props.id] but maybe you meant to write [url] or something like this.
You are correct. That was a copy and paste error. I missed that.
Thank you 😊
Best kind of errors! IMHO..
Thanks for this article 💪 I understand now how to use react hooks 🙃
Your useFetchData example is wrong. Look at the function signature and how you call it.
True, late night posting.. Never a good idea. Fixed it, thanks.
Can we actually make multiple fetches with Promise.all inside an useEffect hook?
I'm not sure the exact question here. But Hooks have a clear set of rules to follow. As well 'useEffect' can be used several times so you that you cad can properly group related code and seperate it from unrelated code. Co-location of your effects
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.