Last active
October 18, 2020 11:37
-
-
Save meetzaveri/a02c35e33db3607ce4fbab2e20742043 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { useEffect } from 'react'; | |
const Container = () => { | |
const userInfo = props.userInfo; | |
const makeAPICall = () => { | |
// do your async actions, side effects or network effects | |
} | |
useEffect(makeAPICall,[userInfo]) | |
return (<div>Example</div>); | |
}; | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment