Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Firebase in React - signInWithPopup() return a blank page

i want try firebase for same project with google auth.

In my react project i have a button with this onPress function =>

import firebase from 'firebase';
const provider = new firebase.auth.GoogleAuthProvider();

handleLogIn() {
    firebase.auth().signInWithPopup(provider)
    .then((result) => {
      // ...
    })
    .catch(function(error) {
      // ...
    });
  }

But this return a blank page...any suggestion?

UPDATE: with signInWithRedirect() it works

like image 873
SaroVin Avatar asked Nov 16 '25 16:11

SaroVin


1 Answers

Blank page opens and closes if the user is already signed in and has provided the required permissions for the application. In that case, the app just returns the data.

like image 177
Deividas Karzinauskas Avatar answered Nov 19 '25 10:11

Deividas Karzinauskas



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!