Created
February 24, 2015 23:42
-
-
Save bjyoungblood/ca5780b9eb983d52b830 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
render() { | |
let body = this.state.smarthome.when({ | |
pending : () => { return <div>Loading...</div>; }, | |
failed : () => { return <div>Error loading smarthome</div>; }, | |
done : (smarthome) => { return <SmarthomeEventsView smarthome={smarthome} />; }, | |
}); | |
return ( | |
<div> | |
<h1>Smarthome! :D</h1> | |
{body} | |
</div> | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
👍