C#C
C#13mo ago
Zoli

How to Filter Firebase Real-Time Data for the Logged-In User in a Maui Application?

In my Maui application, I have successfully implemented email/password authentication and real-time data synchronization. To filter data so that only the logged-in user's relevant documents are shown, should I add a new property (e.g., ownerId) to each document and perform the filtering on the client side?

I saw WhereEqualTo could filter but is this the right approcach to filter on the client by the ownerid?
But it means I need to store the userId on the client, is it safe?

(I saw some relevant questions but they are 6-10 years old and not maui/.net related if matters at all)
Was this page helpful?