Last active
October 31, 2017 17:47
-
-
Save georgesboris/77875726a0d133e3e4c9a645494605e2 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 { paths } from '../firebase-app' | |
import { FirebaseSync, firebaseSyncConnect } from '../firebase-sync' | |
const User = () => ( | |
<div> | |
<FirebaseSync | |
path={paths.user(props.userId)} /> | |
{user && ( | |
<div> | |
<h1>{user && user.name}</h1> | |
<p>{user && user.email}</h1> | |
</div> | |
)} | |
</div> | |
) | |
export default firebaseSyncConnect((state, props) => { | |
return { | |
user: paths.user(props.userId) | |
}; | |
})(User); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment