0

I have build chat UI for my application using react-native-gifted-chat. I have connected the sent messages and received messages with the services. Can anyone help me with the issue of messages not getting updated instantly as the message is received?

Do I need to hit services again and again to refresh the chat message? if yes then how?

Or do I need to implement some kind of push notification? if yes then how?

I just want to make my chat screen update the message instantly when current user receives a message from another user.

behzad
  • 801
  • 3
  • 15
  • 33

1 Answers1

0

Well, for update the message instantly when current user receives a message from another user you need to use firebase realtime database. it provides you to live data instantly..(for more info refer this tutorial https://medium.com/@platypus/react-native-chat-application-679dbff3ccd3)

and for other option Socket.io also provides live data and it is better than firebase realtime database.