Observers
Configure the DataStory
component by setting observers
to monitor changes in the data of the node
<DataStory observers ={ {
// when the portId is not set, monitor all input ports of the node
inputObservers: [{ nodeId: 'Table.1', portId: 'input'}],
onDataChange: (inputObserver, items) => {
// open the devtool console to see the data change
console.log('onDataChange', inputObserver, items);
},
}}/>
attributes
inputObservers: Array<{ nodeId: string, portId?: string }>
onDataChange: (inputObserver: InputObserver, items: ItemValue[]) => void