Created
April 29, 2016 10:17
-
-
Save FaridSafi/d1a2ed36ce84c4bc9960aac1b6b4c6c1 to your computer and use it in GitHub Desktop.
react-native-meteor and react-native-google-signin
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 {GoogleSignin} from 'react-native-google-signin'; | |
import Meteor from 'react-native-meteor'; | |
GoogleSignin.signIn() | |
.then((user) => { | |
Meteor.loginWithGoogle(user, (err) => { | |
if (!err) { | |
// success | |
} | |
}); | |
}) | |
.catch((err) => { | |
// error | |
}) | |
.done(); | |
GoogleSignin.signOut() | |
.then(() => { | |
// success | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment