Controls whether incoming messages are accumulated into the messages array.
true, messages are stored in messages and also delivered to
onMessageReceived and onOldMessagesReceived.false, messages are delivered only via onMessageReceived, onOldMessagesReceived and the
messages array is never populated. Useful for high-throughput topics
(e.g. thousands of messages per second) where retaining a re-rendering
array is undesirable.Hard cap on the number of messages retained in the messages array.
null to retain every message.This represents all persisted messages for the topic.
Unique identifier for the message.
The message content.
Optional additional data sent along with the message.
The ID of the participant who sent the message.
The display name of the participant who sent the message.
Timestamp indicating when the message was published.
The topic under which the message was published.
This represents the topic associated with the PubSub instance.
The message content to be published. This value must be a string.
Optionaloptions: { persist?: boolean; sendOnly?: String[] }Optionalpersist?: booleanWhen set to true, the message is stored for the entire session and is available to newly joined participants.
OptionalsendOnly?: String[]An array of participantId that should receive the message. If not provided, the message is broadcast to all participants.
Optionalpayload: objectAdditional data to be sent along with the message.
persist: true are returned.
usePubSubprovides reactive APIs to publish, subscribe, and access persisted messages for a specific topic within a meeting.