Created
March 24, 2018 13:39
-
-
Save njwest/8505d76353cb9e18627c393677184ef4 to your computer and use it in GitHub Desktop.
src/App.js final render
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
# App.js render method | |
render() { | |
if (this.state.loading) { | |
return ( | |
<Loading size={'large'} /> | |
); | |
} else if (!this.state.jwt) { | |
return ( | |
<Auth newJWT={this.newJWT} /> | |
); | |
} else if (this.state.jwt) { | |
return ( | |
<LoggedIn deleteJWT={this.deleteJWT} /> | |
); | |
} | |
} | |
# snip |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment