All Questions
Tagged with react-native firebase
5,830
questions
145
votes
14
answers
280k
views
Getting all documents from one collection in Firestore
Hi I'm starting with javascript and react-native and I'm trying to figure out this problem for hours now. Can someone explain me how to get all the documents from firestore collection ?
I have been ...
96
votes
15
answers
78k
views
Setting a timer for a long period of time, i.e. multiple minutes
I want to use firebase auth with react native for Login and Signup but I got a yellow error:
Setting a timer for a long period of time, i.e. multiple minutes, is a performance and correctness issue ...
86
votes
4
answers
38k
views
How to determine if JEST is running the code or not?
I am creating a JS test on my react-native project. I'm specifically using firebase for react native, in which I would like to replace firebase instance with a mockfirebase instance if JS is running ...
66
votes
12
answers
33k
views
Is there a workaround for the Firebase Query "IN" Limit to 10?
I have a query for firebase that has an array of IDs that has a size > 10. Firebase has restrictions on the number of records to query in one session. Is there a way to query against more than 10 at a ...
60
votes
22
answers
103k
views
APNS device token not set before retrieving FCM Token for Sender ID - React Native Firebase
I have been following this tutorial to set-up Remote Push notifications on my react-native application using react-native-firebase Version 5.2.0. After I configured everything and ran the application ...
50
votes
10
answers
33k
views
React-native bundling failure. ERROR MESSAGE: "While trying to resolve module 'idb'..... Indeed none of these files exist":
ERROR MESSAGE IN QUESTION:
While trying to resolve module idb from file C:\Users\OG\Desktop\programming\react_native\mealstogo\MealsToGo2\node_modules\@firebase\app\dist\esm\index.esm2017.js, the ...
50
votes
6
answers
12k
views
Firebase Messaging on Android suddenly started crashing when message received
Currently using react native, react-native-firebase, and react-native-push-notification. Everything was fine until suddenly today firebase messaging started causing the app to crash. The error message ...
49
votes
5
answers
36k
views
How to add multiple docs to a collection in firebase?
Im working with React native and react-native-firebase
My objective is to add multiple docs(objects) to a collection at once.
Currently, I have this:
const array = [
{
name: 'a'
},{
...
46
votes
2
answers
3k
views
Firebase phone auth Error: Invalid token. at nativeToJSError
I am using firebase phone auth in react native app with this docs, I tested it in some different devices. sometimes the phone auth works and sometimes it throws this error
firebase phone auth Error:...
41
votes
1
answer
25k
views
The identity provider configuration is not found - React Native Firebase Authentication with FacebookAuthProvider
The identity provider configuration is not found
I am getting this error when I try to authenticate to firebase using FacebookAuthProvider. I am using react-native-fbsdk for facebook authentication ...
32
votes
6
answers
12k
views
firebase firestore adding new document inside a transaction - transaction.add is not a function
I was assuming that it was possible to do something like:
transaction.add(collectionRef,{
uid: userId,
name: name,
fsTimestamp: firebase.firestore.Timestamp.now(),
});
But apparently it is not:...
28
votes
1
answer
2k
views
How can I resolve crash Thread SIGSEGV 0x0000000000000010 in react native
I have an application published in Play Store,
I got a crash report but I can't figure out how to resolve it,
Trace:
Crashed: Thread: SIGSEGV 0x0000000000000010
at (Manquant)()
at (Manquant)()
...
26
votes
5
answers
21k
views
Enable Firebase debugView Events in React native
I have been trying to connect my ReactNative App to firebase for two reasons -
1. Push Notifications ( Done Successfully )
2. Events logging for each user.
I am facing issues with debugView to get ...
23
votes
13
answers
73k
views
Java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/firebase/FirebaseApp
This is React Native project. I have an error after successful build in Android Studio Emulator:
java.lang.NoClassDefFoundError: Failed resolution of:
Lcom/google/firebase/FirebaseApp
My files:
...
23
votes
6
answers
43k
views
Convert image path to blob react native
Problem
I am trying to create an app with react native and firebase. One of the features I would like for this app is the ability to upload images. I am having some trouble uploading the images to ...
23
votes
6
answers
5k
views
Error when running Firebase 3.0 with React Native
Just loaded firebase 3.0 with react-native and getting the error
[fatal][tid:com.facebook.react.RCTExceptionsManagerQueue] Unhandled
JS Exception: Can't find variable: document
Is react-native ...
23
votes
1
answer
4k
views
Firebase & iOS 14 > Will dynamic links tracking and campaigns continue to work?
As most of you are probably aware, iOS 14 will basically put an end to app acquisition tracking as we know it.
Here are two great articles that explore the issue in length:
The App Attribution ...
22
votes
3
answers
19k
views
React Native - Firebase auth persistence not working
Firebase auth does not persist logged in user and everytime I refresh or reopen app I have to sign in again.
I have tried setting persistence to local and the callback does verify its set but the ...
22
votes
5
answers
10k
views
Firebase Storage: String does not match format 'base64': Invalid character found
I'm working on a react-native and I need to upload an image to Firebase using Firebase Storage. I'm using react-native-image-picker to select the image from the phone which gives me the base64 encoded ...
22
votes
4
answers
48k
views
Tried to get frame for out of range index NaN (realtime database)
I'm trying to render some rows from firebase database, I'm getting this error:
TaskQueue: Error with task : Invariant Violation: Tried to get frame
for out of range index NaN
const { ...
22
votes
4
answers
7k
views
com.segment.analytics.android:analytics error while submitting my app to Google Play Console
I am trying to submit my React Native EXPO app to Google Play Store for approval, but I am getting this error:
SDK Segment Analytics Android (com.segment.analytics.android:analytics), 4.9.4 collects ...
20
votes
6
answers
15k
views
react-native-firebase crashlytics not showing up on firebase dashboard
I am using firebase crashlytics. I am causing a crash by doing
firebase.crashlytics().crash()
and I am not seeing the crash report on the firebase dashboard. The crash is working because on android ...
20
votes
1
answer
1k
views
Firebase 3.3 realtime database stuck to "Making a connection attempt" with React Native 0.32
[email protected]
react-native v0.32 tested on android device with wifi
Firebase database doesn't have any auth rules, it's open read and write.
Given the following file structure :
|_ firebase.js
|_ ...
19
votes
3
answers
32k
views
Error: auth/configuration-not .An internal error has occurred
any Idea why I m getting this issue when I click on sign Up by email and password in React-Native and Firebase ?
[Error: [auth/configuration-not] An internal error has occurred. [ ...
19
votes
2
answers
8k
views
How can we use Firebase Analytics with an expo based react-native app
I am trying to add Firebase Analytics (FA) to my react-native app.
Actually, I didn't find a problem to put Google Analytics (GA) using this library expo-analytics.
But apparently Firebase analytics ...
19
votes
4
answers
8k
views
What's the difference between Firebase JavaScript SDK and react-native-firebase
I am trying to use to use Firebase (Cloud Firestore) for a react-native app, to store my JSON objects.
I ve seen people using Firebase in their apps (npm install firebase), and others using react-...
19
votes
9
answers
30k
views
error: bundling failed: TypeError: Cannot read property 'transformFile' of undefined, React Native
I receive this error whenever I run react-native start, but this started happening recently after I had installed firebase-tools and stripe in my node modules, but before that it would run just fine, ...
18
votes
3
answers
12k
views
Android build doesn't work (Duplicate class com.google.android.gms.internal.measurement.zzbt found in modules)
It worked fine until a week ago, but this week the build didn't work and I got the following error.
I tried the following, but I haven't solved it yet.
Any small thing is fine, so if anyone knows any ...
18
votes
3
answers
6k
views
Firebase - Perform Analytics from database/firestore data
I am using Firebase as my authentication and database platform in my React Native-Expo app. I have not yet decided if I will be using the realtime-database or Firestore database.
I need to perform ...
18
votes
1
answer
6k
views
Facebook login in react-native & firebase 3.1
Recently firebase team have released their new version 3.1 of firebase which is compatible with react-native. I'm trying to use the new firebase api with facebook.
Since firebase doesn't support ...
17
votes
2
answers
13k
views
What is the best practice of firestore data structure?
I'm making a blog app using firebase.
I want to know the best practice of data structure.
As far as I know, there are 2 case.
(I'm using react native)
case 1:
posts
-postID
-title,content,...
17
votes
2
answers
17k
views
How to link Firebase's Authentication to Realtime Database?
As the title said.
I need to link authenticated user to database.
So that different user can only see their data.
I had successfully implement the Authentication function of Firebase.
But the record ...
16
votes
6
answers
9k
views
Cannot import `getReactNativePersistence` in `[email protected]`
I cannot import the getReactNativePersistence module from the firebase/auth. I'm using Typescript.
Importing the function as below was possible, but it didn't work when I updated the Firebase SDK from ...
16
votes
5
answers
25k
views
Firebase Detecting if user exists
How Can I Check user exists in Firebase auth in Signup Button via react native?
This is my Login Page Code:
export default class Login extends Component {
constructor(props) {
super(...
16
votes
7
answers
18k
views
ld: library not found for -lFirebaseCore clang: error: linker command failed with exit code 1 (use -v to see invocation)
I using react-native-fcm for remote push notification but it gives this error:
ld: library not found for -lFirebaseCore
clang: error: linker command failed with exit code 1 (use -v to see invocation)
...
16
votes
2
answers
35k
views
How can scheduled Firebase Cloud Messaging notifications be made outside of the Firebase Console?
Inside the Firebase Console, under the Cloud Messaging view, users are able to create test notifications. This functionality also allows you to schedule the time at which the notification will send to ...
16
votes
3
answers
7k
views
Can't get data from React-Native-Firebase(v6) Firestore: undefined is not a function (near '...this._firestore.native.collectionGet...')
I've been stuck on this issue for so long. I just started implementing Firestore in my react-native application with react-native-firebase. I'm just following the docs [https://invertase.io/oss/react-...
16
votes
1
answer
35k
views
Handling logout properly with React Native
I have a react native application that show's different navigators based on whether or not there is an authenticated firebase user.
Here's my main App class:
export default class App extends ...
16
votes
2
answers
11k
views
How to use array-contains operator with an array of objects in Firestore?
So, i want to query some data from firestore.
this is my data structure
so, the collection is Modules, then i now have 2 documents but it will be 75 or something. Then in that document i want to get ...
16
votes
2
answers
16k
views
ERROR: Could not find method platform() for arguments - React Native - Firebase
Has anyone faced this issue following the official documentation for react-native-firebase?
ERROR: Could not find method platform() for arguments [com.google.firebase:firebase-bom:21.1.0] on object ...
16
votes
2
answers
24k
views
How do I link auth users to collection in Firestore?
I'm trying to connect a user to the user collection in firestore. I'm using cloud functions, but I don't think I'm implementing it correctly.
firebase.auth().createUserWithEmailAndPassword(email, ...
15
votes
5
answers
20k
views
Can't find a variable atob
Screen1.js
import React,{useEffect} from 'react'
import {View,Text} from 'react-native'
import * as firebase from 'firebase/app';
import '@firebase/firestore';
const Screen1 = props =>{
...
15
votes
7
answers
21k
views
`Firebase` package was successfully found. However, this package itself specifies a `main` module field that could not be resolved
I'm trying to read and write to firestore, use firebase's authentication, and firebase's storage within a expo managed react-native application.
Full Error:
While trying to resolve module `firebase` ...
15
votes
4
answers
31k
views
How to get all of device tokens from Firebase?
How to get device tokens (FCM registration tokens) from Firebase?
I'm making mobile app using firebase and its server using node.js.
I want to send push notification message from server, but I don'...
15
votes
1
answer
9k
views
Arrays vs. Maps vs. Subcollections for a set of Objects on Cloud Firestore
I am developing a mobile app in React-Native. Data is stored on Cloud Firestore. I have a question regarding the best way of structuring the data on Cloud Firestore.
The list of contacts, which every ...
15
votes
4
answers
6k
views
RNFirebase core module was not found natively on android
I am trying to run an existing react native app on android platform and I am getting the error as in the below image. I have already followed all the steps mentioned under http://invertase.link/...
15
votes
2
answers
2k
views
react-native google api restrictions
When using firebase or react-native-google-places-autocomplete, I need to supply an api key.
Obviously, I can't use a native api key, as the calls are made using web clients. So I have to use a web ...
14
votes
5
answers
17k
views
Could not reach Cloud Firestore backend - React native Firebase v9
I saw many questions on SO regarding this issue and none of them was answered (or the solution doesn't work), I don't know why. People are having this error continuously but no solution is being ...
14
votes
2
answers
28k
views
Calling async function inside non-async function in React-Native - Firebase
This is what I'm trying do in React-Native. Async functions are making calls to firebase.
async functionOne() {
asyncStuffHappens
}
functionTwo() {
this.functionOne();
}
this....
14
votes
4
answers
9k
views
firebase: can't find variable IDBIndex
I'm developing an app with react-native (v0.60) and I need push notifications. I decided to use firebase as service but I have an error during initialisation.
Code:
import {AppRegistry} from 'react-...