import { useStores } from 'fluxible-hooks';
const User = ({ userId }) => {
const { firstName, lastName } = useStores([UserStore], context => {
context.getStore(UserStore).getUser(userId)
});
return <p>{firstName} {lastName}</p>;
}
...
<User userId={15}/>
porchdotcom / fluxible-hooks Goto Github PK
View Code? Open in Web Editor NEWThis project forked from pwmckenna/fluxible-hooks