Skip to content

Latest commit

 

History

History
57 lines (33 loc) · 1.92 KB

common-liveUpdate-options.md

File metadata and controls

57 lines (33 loc) · 1.92 KB

Live Update

no shift

If the series.shift option is not set to true, when the new data is added through addData(), the chart automatically shifts as shown above. However, this could lead to problems when the amount of data increases. This problem can be addressed through the Live Update feature.

live update line

The Live Update feature allows the chart to show the adding of the new data when addData() API is called according to the predetermined size.

Applying Live Update

  1. Set the series.shift option to true.
const options = {
  series: {
    shift: true
  }
}
  1. Use the addData API to add data.
const chart = new LineChart({ el, data, options });

chart.addData(newData, newCategory);

Compatible Charts

The following is a list of charts compatible with Live Update.

live update line

area

lineArea

column

columnline

heatmap