I am very new to react native but wish to create a mobile application, I have a couple of questions which I would be very grateful if someone could please help.
Firstly A question about authentication. This boggles my mind completely.
In my application I would like the end user to be able to authenticate via both Google and Facebook, but I don't understand how these link to the same account in the backend
For example, User A firstly logs into app using google, uses it for a while. They then log out and re-authenticate with facebook, this links them to the first login with Google. How? When I auth with both Google and Facebook I see nothing that links them other than their name and sometimes email address, Am I missing something? how would I allow authentication with both that would then point to same point at backend?
Secondly I am using redux for managing my states.
when I load up my state is it ok to do the following
componentWillMount(){
this.state = this.props.reducerState
}
then if I dispatch an action to update the reducer would the state update automatically, or is this the wrong approach, I just don't know exactly what to do as I have a file with my states in, should I be importing that to the component directly?
Because I was reading updating props doesn't init an re-render of component. I would really need a component to update when an action is called and the redux state changes.
thanks guys