DEV Community

Discussion on: How to use async function in useEffect?

Collapse
 
jasmin profile image
Jasmin Virdi • Edited

Thanks for sharing🙌

Agreed, this is not recommended. Wanted to throw some light on ways with reasoning.

Collapse
 
peerreynders profile image
peerreynders

There was this talk, "When To Fetch", recently at Reactathon 2022

"You need to initiate fetches before you render"