I am having problems doing login
in react-native
, I followed all the corresponding steps, and at the time of logar
it presents the following error
cannot read property 'logInWithReadPermissions' of undefined
import FBDSK, { LoginManager } from 'react-native-fbsdk'
_fbAuth() {
LoginManager.logInWithReadPermissions(['public_profile', 'email']).then(
function(result) {
if (result.isCancelled) {
alert('Login cancelled');
} else {
alert('Login success with permissions: ' +
result.grantedPermissions.toString());
}
},
function(error) {
alert('Login fail with error: ' + error);
}
);
}