All Questions
Tagged with google-cloud-firestore typescript
1,294
questions
0
votes
0
answers
20
views
Firebase DocumentReference and Timestamps being lost? [closed]
I'm in the midst of a rework for one of the contexts in my project. It was previously all fetched and filtered on the front end but I was noticing performance issues with large data sets. I decided to ...
0
votes
1
answer
23
views
Firestore rule denying request which supposed to be allowed
I have this TypeScript React code, for fetching a firestore collection (using react-firebase-hooks):
const [membersSnapshot, loading, error] = useCollectionData(
query(
collection(db, ...
0
votes
2
answers
33
views
How to pass value or variable outside of onAuthStateChanged?
I'm currently trying to get authenticated user's uid from google authentication for specific collection from "User" document. I'm using onAuthStateChanged is to prevent data went null after ...
1
vote
1
answer
34
views
How do you retrieve most recent Post from a collection of 'posts' in Firestore using Angular?
I'm new to Firebase and Angular and I'm making a Twitter mock-up for practice. I have it to where a user can make a Post and it saves to a collection of 'posts' in Firebase. Now, I'm trying to get it ...
0
votes
1
answer
32
views
Firestore returning undefined when trying to get array field from document
I'm trying to get the players array from this Firestore document you can see in the screenshot, in order to update it with a POST call.
My issue is that whenever I get this document, calling doc.data()...
0
votes
0
answers
19
views
Unexpected Firestore Query Behavior When Limit Exceeds Item Count
I have a Firestore query that looks like this:
query = query.where(fieldName)
);
this.subscription = query
.orderBy("time", "desc")
.endAt(this.firstReference)
.limit(3);
...
0
votes
1
answer
49
views
cloud functions: 'event.data' is possibly 'undefined'
I have been trying to write cloud functions(for firebase) for my project and I am stuck at writing cloud function syntax in typescript. I have watched a couple videos related to cloud functions at SQL-...
0
votes
1
answer
25
views
Firebase timestamps with Typescript
I'm trying to figure out the nightmare of dates with Firebase.
I declare my objects with types as follows:
export type FirebaseTimestamp = { _seconds: number, _nanoseconds: number }
type MyObject = {...
0
votes
1
answer
44
views
Unable to convert to type from Firestore in Angular
I'm trying to convert data from Firestore into a type in Angular. Though I'm struggling on how to use a converter.
This is my model:
import { QueryDocumentSnapshot } from "@angular/fire/firestore&...
0
votes
0
answers
22
views
Is there a way to update with a map of FieldPaths
So in Dart I can do this pretty easily:
final map = <Object, dynamic>{};
map[FieldPath('complex.key', 'other')] = 'my value';
docRef.update(map);
This isn't possible in TS/JS though, as you can'...
1
vote
1
answer
45
views
Needing to reload data on route change using same component - React TSX
Right now, I'm having trouble as my data that I am receiving from Firebase Firestore is able to load on both routes, however, it only does so if I click twice on the route link otherwise the old data ...
0
votes
0
answers
51
views
Firebase doc does not accept the path specified using the received useRouter id in next.js
I want to get data about the project, but I can’t do it dynamically, it just doesn’t accept the id.
const router = useRouter();
const {projectID} = router.query;
const getProject = doc(firestore, `...
0
votes
2
answers
167
views
redux toolkit query,unable to return value with with transformResponse using queryFn
I would like to modify the response received from the backend with the transformResponse function but I get an error even when I only return the first argument ""baseQueryReturnValue"&...
0
votes
0
answers
54
views
Error regarding firebase onSnapshot context on refresh in Next 14 app router application
I was wondering if anyone could chime in and help me figure out how to solve this issue I'm having. I am using Next 14 with app router. Any help would be greatly appreciated!
My app is set up in the ...
0
votes
0
answers
11
views
Data classes for Firebase and Firebase Admin [duplicate]
I was writing a project using firebase firestore, and I made some data classes, so that I could access the data in a better way. The problem I'm facing is that the firestore classes are not compatible ...