title: undefined is not an object firebase.auth.FacebookAuthProvider.credential
body: <p>Here is my code.. its pretty simple.. just trying to allow a user to authenticate through facebook and then add it to the Firebase system!
  I should mention that I am using React Native, I did read that various parts of the Firebase library does not work with React Native.</p>
  
  <pre><code>const auth = firebase.auth();
  const provider = firebase.auth.FacebookAuthProvider;
  
  LoginManager.logInWithReadPermissions(['public_profile'])
  .then(loginResult =&gt; {
  
      alert("login results")
      if (loginResult.isCancelled) {
          alert('user canceled');
          return;
      }
      AccessToken.getCurrentAccessToken()
      .then(accessTokenData =&gt; {
          const credential = firebase.auth.FacebookAuthProvider.credential(accessTokenData.accessToken);
          alert("Credential: " + credential )
          return auth.signInWithCredential(credential);
      })
      .then(credData =&gt; {
          console.log(credData);
          alert("CRED data:::" + credData)
          alert(firebase)
      })
      .catch(err =&gt; {
          console.log(err);
          alert("ERROR:::" + err)
          alert(firebase)
  
      });
  });
  </code></pre>
  
  <p>The only reasoning I can really think of for this is that Firebase is undefined or it does not finish initializing.. although it seems to be.. maybe I can put in some sort of promise to ensure it has initialized.
  (Any ideas on how to do that?)</p>
  
  <p>Although firebase seems to be initalized.. but I went through the api reference and can't really find any reason why .auth.FacebookAuthProvider.credential would not exist</p>
  
  <p>Any help would be great!</p>