Closed jenlikescode closed 7 years ago
It looks like you were able to figure this out okay?
If not, you can pass the result of Meteor.user()
directly as a prop without the need to do a JSON.stringify()
; React will interpret it as an object and you can use it like user.emails[0].address
, etc.
What was the answer to this question? I am also trying to create a profile page but having trouble. Can this be something that can be added to a future base update? Thanks
First, thank you for creating Base. It's been really helpful as I move from the Meteor/Blaze to Meteor/React world.
It's straight forward to pass subscription data to components via containers. But, trying to create a basic profile page has been surprisingly hard and I feel like I'm missing something simple. So far I've managed to pass the user object as a json string.
My question is- what is the best way to pass a logged in user's info to a react component?
In my container, I have...
And my component...