Hello I am trying to implement the facebook login using the ionic services but the documentation is not clear on the details, or maybe I am missing something…
Does anyone have a working example?
This from the documentation
Injecting FacebookAuth and User
Import FacebookAuth and User from the Cloud Client and specify them as dependencies in your component constructor.
facebookAuth is a service that deals with user authentication.
user is a reference to the current user, whether that user is anonymous or authenticated.
import { Component } from ‘@angular/core’;
import { FacebookAuth, User } from ‘@ionic/cloud-angular’;
@Component( … )
export class LoginPage {
constructor(public facebookAuth: FacebookAuth, public user: User) {
…
}
}
Login
this.facebookAuth.login().then( … );
Logout
Logging out clears the current user context.
hello, Excelent tutorial. Just wanted to ask you how where you able to debug this on your local environment? I am only able to test this on the real device. Thanks!
Hi, nice movie. I followed the instructions but unfortunately I get an empty error object after pressing ‘continue’ in the Facebook prompt.
When I press cancel I get an error object with the message that the user cancelled. But pressing continue thus results in an empty error… Do you have any idea why?