Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

187
Views
React JS / How data in Firebase can communicate with each other?

I am making a social media app, I need logic for user chat, how to make communication between a user who is active and a user who is selected from registered users? How to see only messages between two users? And later, I can choose another registered user and communicate with him independently from other registered users? I use react js, firestore database. For now, I have a users collection that has a UID identical to the UID auth, i.e. the UID of a registered user through firebase auth, and within the users collection I have a messages subcollection where each user sees his messages, when I open another window to achieve websocket realtime communication, in the chats window I see only the messages of one user it is the one who sent or received, but those messages are not in the same place? If I create a collection of messages, then I will have messages that will be for all users, the so-called group chat, and that's what I don't need, that's why I created a subcollection for each user to have their own messages, and now I should share that with the selected user only if there is communication I will also need this logic for posts where each user will be able to see their post and the post of those they follow on the social media app, so if you have any tips that would be great, I've been stuck here for a while.. Thanks!

https://ibb.co/vZzdjc6 https://ibb.co/64y28mZ

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!