Skip to content

[Feature] When asynchronous data is set dynamically, does it make a difference if setOption sets other static data again? Example: Performance  #16351

@jahnli

Description

@jahnli

What problem does this feature solve?

When asynchronous data is set dynamically, does it make a difference if setOption sets other static data again? Example: Performance

Dynamically updating data ,Is there a difference between the two approaches?
1.

myChart.setOption({
    title: {
      text: '异步数据加载示例'
    },
    tooltip: {},
    legend: {},
    xAxis: {
      data: data.categories
    },
    yAxis: {},
    series: [
      {
        name: '销量',
        type: 'bar',
        data: data.values
      }
    ]
  });

2、

  myChart.setOption({
    xAxis: {
      data: data.categories
    },
    series: [
      {
        // 根据名字对应到相应的系列
        name: '销量',
        data: data.data
      }
    ]
  });

What does the proposed API look like?

More detailed documentation

Metadata

Metadata

Assignees

No one assigned

    Labels

    enThis issue is in Englishnew-featurependingWe are not sure about whether this is a bug/new feature.staleInactive for a long time. Will be closed in 7 days.waiting-for: community

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions