I am working on a React App. The app has basic auth features. Here is the code below. The issue here is that i am trying to create a custom alert for a specific error that is “The Email ID Already Exists”. But Firebase has its own predefined error template defined for it. And when I replace with a custom
Tag: firebase
ReactJS/Firestore: how to get the id of a newly created document
Using ReactJS and firebase, I’m trying to create a new document with sub-collections, so I need (I believe) to get the id of the document in order to reference the correct path to add the sub collections : Here is my Firestore : I created the collection “general_info” manualy, I’m trying to do it with code. Answer The addDoc() returns
react website not loading with firebase. What am I doing wrong?
I looked at the suggestions online for how to fix firebase, but they didn’t work. I tried setting my firebase.json hosting feature where says “public” to “build”, but that didn’t work so what else should I do? I don’t get errors when I compile it, but the website is blank when I run “npm start”. Here is the relevant javascript
How do I get database data using firebase/nuxtjs
I don’t know how to get the data via I’ve read the firebase docs but in firebase/nuxtJs different it becomes easier https://firebase.nuxtjs.org/ In firebase docs But when I call onValue, it doesn’t find it nuxt.config.js file Answer Simply simple explanation : in Realtime Database : Whenever the value is changed, the function will run
Validating Firebase Auth tokens manually
I’m trying to use cloudflare workers to perform authenticated actions. I’m using firebase for authentication and have access to the Access Tokens coming through but since firebase-admin uses nodejs modules it can’t work on the platform so i’m left manually validating the token. I’ve been attempting to authenticate with the Crypto API and finally got it to import the public
Use firebase onSnapshot() in for loop?
The below code works for getting my data from firestore. I’m trying to update this to use onSnapshot() instead of of get(). Maybe the core of my confusion is onSnapshot() doesn’t return a promise and I’ve tried just adding the listeners into an array but it seems the data doesn’t get updated. How do I iterate over a for loop
Uncaught (in promise) FirebaseError: Expected type ‘rc’, but it was: a custom ac object
The error happens in this code: ** I am trying from 2 days but can’t understand what’s the problem !!** I am trying to add an array in firebase , i am tring so many solution but can’t get what’s the problem !! Answer The setDoc() function takes a DocumentReference as first parameter but you are passing a CollectionReference. If
How to check current password when reset password in firebase and Expo? [closed]
Closed. This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed 11 months ago. Improve this question I’m adding password reset function using react native expo and firebase api. First input is current password. Second input is
Get points of user that is currently logged in from realtime database
I want to get the points and show to the owner of that account when he is logged in I tried reading firebase documentation but I couldn’t made it here is the code that I use for assigning the random key and saving the child data I want whenever the user is login get his points from database and show
There was an error deploying functions. Failed to update function app in region us-central1
This is my first time trying to deploy a function firebase function. I’ve written an API and I want to create a firebase function and use it. In my project everything works on localhost and even worked when I did firebase serve –only functions, hosting. Since I’m only using hosting and functions I didn’t do the initializeApp(firebaseConfig) thing of firebase