Authentication with Firebase Simple Login

I can’t find the answer on Firebase Google Group. The google group is too chaotic. I prefer this forum. Anyone has this problem?

nevermind. found the solution.

It might be helpful to others if you share the solution.

I am using https://www.firebase.com/docs/security/simple-login-overview.html, facebook (https://www.firebase.com/docs/security/simple-login-facebook.html). I placed https://auth.firebase.com/auth/facebook/callback in the wrong location. The correct location: "Facebook application configuration, go to the “Settings” tab and set your ‘Site URL’. (https://developers.facebook.com/apps)

@Calendee We should open a separate forum category here for ‘General app development’ or ‘AngularJS questions’.

It seems that the Ionic community wants to help each other out even if their problems arent directly Ionic related but now all these questions are asked in the ‘Ionic’ forum.

2 Likes

We had a bunch of other categories for a while. It just got confusing. It’s hard to know where to post; so Max pulled them all.

Ah ok. Haha.

Let’s just make one big confusing category instead of multiple confusing categories. Makes sense, seems like less confusion this way :wink:

1 Like

Hi @rdtran

Did you get Firebase Simple Login working with Ionic?
Could you post an example?

insert it in your controller. you can look at this, https://www.firebase.com/docs/angular/reference.html

  // perform the login auth
    var chatRef = new Firebase('https://your-firebase-name.firebaseio.com');
    var auth = new FirebaseSimpleLogin(chatRef, function(error, user) {
      if (error) {
        // an error occurred while attempting login
        console.log(error);
      } else if (user) {
        // user authenticated with Firebase
        console.log('User ID: ' + user.id + ', Provider: ' + user.provider);
      } else {
        // user is logged out
      }
    });
    
    auth.login('facebook');	
1 Like