Real-time updates are the most important part of building an instant chat messaging application. Stringee provides simple methods to register and listen for events, as described in Connecting. You need to implement onObjectChange event to get Conversations, Messages updates.
import {ChangeType, ObjectType} from 'stringee-react-native-v2';
stringeeClientListener.onObjectChange = (stringeeClient, objectType, objectChanges, changeType) => {
console.log('onObjectChange: ', objectType, objectChanges, changeType);
};
In which:
ObjectType.conversationObjectType.messageChangeType.insert: Notify an object is created or inserted.ChangeType.update: Notify the object is updated.ChangeType.delete: Notify the object is deleted.