Created
April 27, 2017 15:34
-
-
Save jasdeepsingh/39b251c5e24f52810732c3ae1bf2f20d to your computer and use it in GitHub Desktop.
react component
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
class Component extends React.Component { | |
component___Mount() { // didMount? willMount? | |
window.api.asyncCallToBackend() // returns promise | |
} | |
render() { | |
return (<data here that depends on response of async call in one lifecycle methods>) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment