Giter VIP home page Giter VIP logo

Comments (3)

ursvasan avatar ursvasan commented on May 30, 2024

I figured I didnt include the line

import { firebase } from '../../firebase/config'

in RegistrationScreen.js and thats the reason for the above error. Now firebase is loading but still registration screen is not working.
I get the following error when i call firebase.auth() in RegistrationScreen.js > onRegisterPress

Uncaught TypeError: _firebase_config__WEBPACK_IMPORTED_MODULE_4__.firebase.auth is not a function

I have the following in ./src/firebase/config.js


var firebase = require("firebase/app");
require("firebase/auth");
require("firebase/firestore");

const firebaseConfig = {
  apiKey: 'xxxxx',
  authDomain: 'abcd.firebaseapp.com',
  databaseURL: 'https://xyz.firebaseio.com',
  projectId: 'xyz',
  storageBucket: 'xyzappspot.com',
  messagingSenderId: '12345',
  appId: '1:123456',
};

firebase.initializeApp(firebaseConfig);
console.log(firebase);
export { firebase };

from react-native-firebase.

ursvasan avatar ursvasan commented on May 30, 2024

Turns out I am using Firebase 9.x and it has lot of breaking changes and this tutorial is based on a older version. For the latest changes refer to the article

from react-native-firebase.

rybaier avatar rybaier commented on May 30, 2024

@ursvasan I know this is a bit late but if you wanted a reference for the Firebase 9 modular SDK you can find it here @
https://github.com/rybaier/react-native-firebaseModular ( I updated all the syntax and made a pull request)

I also created my own repo of it and added a few more features like SSO for Google and Apple, deleting accounts, update and delete for entities, and log out. you can find it here @ https://github.com/rybaier/react-native-firebase.

from react-native-firebase.

Related Issues (13)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.