Record data changed listener, used to be notified whenever the record data has been modified either locally or remotely.
Methods
onRecordChanged(_:data:)
func onRecordChanged(_ name: String, data: JsonElement) -> Void
argument | type | description |
---|---|---|
name | String | The name of the record that changed |
data | JsonElement | The updated data |
Called when the listener is added via Record.subscribe(_:triggerNow:)
Will contain the entire record data, regardless of whether triggered by a Patch or Update