1

i have the next code:

let vm = this;
         console.log("LOGIN FACEBOOK WEB");
         const provider = new firebase.auth.FacebookAuthProvider();
         firebase
            .auth()
            .signInWithPopup(provider)
            .then(function(result) {
                console.log(result);

            })
            .catch(function(error){
                console.log(error);
            });

But I receive the following error in the console:

TypeError: Cannot set property 'href' of undefined

I already have the project set up in facebook developers and in firebase authentication The url I am working on is local: http://localhost:8081/entrar/

Curiously when you start enable toggle device toolbar if you perform the redirect action to the login page. But then the other error comes up:

code: "auth / canceled-popup-request"
message: "This operation has been canceled due to another conflicting popup 
being opened."

What could be my mistake?

Doug Stevenson
  • 297,357
  • 32
  • 422
  • 441
JG_GJ
  • 755
  • 1
  • 10
  • 33

1 Answers1

0

Authenticate with Firebase using the Google provider object. You can prompt your users to sign in with their Google Accounts either by opening a pop-up window or by redirecting to the sign-in page. The redirect method is preferred on mobile devices.

original answer: Progressive Web App (PWA) in standalone mode OAuth error

daniel gi
  • 396
  • 1
  • 7
  • 19