Skip to content
Main Navigation Guide
Chart API
Instance API
ProPreviewCustomizeSponsor
9.x Docs
8.x Docs

🇬🇧 English

🇨🇳 简体中文

🇬🇧 English

🇨🇳 简体中文

Appearance

Sidebar Navigation

getDom

getSize

setStyles

getStyles

setFormatter

getFormatter

setLocale

getLocale

setTimezone

getTimezone

setThousandsSeparator

getThousandsSeparator

setDecimalFold

getDecimalFold

setOffsetRightDistance

getOffsetRightDistance

setMaxOffsetLeftDistance

setMaxOffsetRightDistance

setLeftMinVisibleBarCount

setRightMinVisibleBarCount

setBarSpace

getBarSpace

setSymbol

getSymbol

setPeriod

getPeriod

setDataLoader

resetData

getDataList

getVisibleRange

createIndicator

overrideIndicator

getIndicators

removeIndicator

createOverlay

overrideOverlay

getOverlays

removeOverlay

setPaneOptions

getPaneOptions

setZoomEnabled

isZoomEnabled

setScrollEnabled

isScrollEnabled

scrollByDistance

scrollToRealTime

scrollToDataIndex

scrollToTimestamp

zoomAtCoordinate

zoomAtDataIndex

zoomAtTimestamp

convertToPixel

convertFromPixel

executeAction

subscribeAction

unsubscribeAction

getConvertPictureUrl

resize

On this page

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, and getBars is completed.
    • unsubscribeBar Unsubscribing from real-time data will be triggered after setting the transaction pair information and the period.

Returns ​

setDataLoader returns undefined 。

Usage ​

Basic ​

Edit this page on GitHub

Last updated:

Pager
Previous pagegetPeriod
Next pageresetData

Released under the Apache License V2.

Copyright © 2018-2025 liihuu