Skip to content
Advertisement

Tag: firebase

Getting ‘firestore/permission-denied’ while integrating firestore in React native mobile app

I’m trying to firestore documents through react native app, but facing the following issue Here is the code and we are triggering button click we are facing this issue Error: Firestore: The caller does not have permission to execute the specified operation. (firestore/permission-denied). Error: Firestore: The caller does not have permission to execute the specified operation. (firestore/permission-denied). Answer If this

Append to an arary field in Firestore

I’m using Firebase and Vuejs to create an database element, which has object array inside. That’s how the field looks, and I want to add tasks through the form into the ‘moreTasks’ as an array. I tried using this, but it just creates new entity in the database. I also tried checking API but I couldnt understand the refs, because

Firestore: Multiple conditional where clauses

For example I have dynamic filter for my list of books where I can set specific color, authors and categories. This filter can set multiple colors at once and multiple categories. How can I add “where” conditionally? Answer As you can see in the API docs, the collection() method returns a CollectionReference. CollectionReference extends Query, and Query objects are immutable.

firebase.firestore() is not a function when trying to initialize Cloud Firestore

When I try to initialize Firebase Cloud Firestore, I ran into the following error: Uncaught TypeError: WEBPACK_IMPORTED_MODULE_0_firebase.firestore is not a function I installed firebase with npm install firebase –save previously. Answer I fixed it by importing multiple libraries: firebase and firebase/firestore. That’s because the firebase core library does not include the firestore library.

Advertisement