Relative Content

Tag Archive for reactjstypescriptfirebasefirebase-realtime-database

Firebase DocumentReference and Timestamps being lost?

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 move it so that the data is fetched from a cloud function and stored in the context. Since doing so I’ve noticed that when I update documents that the fields that were previously stored as DocumentReferences and Timestamps are now being saved as maps that essentially mimic timestamps/references. How do I prevent this conversion from happening and ensuring these data types are maintained?