setDataLoader(dataLoader)
setDataLoader
set up the data loader.
Reference
typescript
(
dataLoader: {
getBars: (params: object) => void | Promise<void>
subscribeBar?: (params: object) => void
unsubscribeBar?: (params: object) => void
}
) => void
Parameters
dataLoader
Data loader.getBars
Get data, which will be triggered when setting the trading pair information, setting the period and dragging the chart to the left or right boundary.subscribeBar
Subscribing to real-time data will be triggered after setting the trading pair information, setting the period, andgetBars
is completed.unsubscribeBar
Unsubscribing from real-time data will be triggered after setting the transaction pair information and the period.
Returns
setDataLoader
returns undefined
。