[Bug] MarkLine does not render
- Dominant language
- TypeScript
- Stars
- 67.3k
- Forks
- 19.8k
- Avg merge
- 11d 14h
- Merged PRs (30d)
- 8
Description
### Version
5.6.0
### Link to Minimal Reproduction
https://jsfiddle.net/pL8u97sz/4/
### Steps to Reproduce
1. call `setOption` with series without markLine
2. call `setOption` again but spread the previous options and adds series with the markLine
```
chart.setOption({
xAxis: {
type: "value",
},
yAxis: {
type: "value"
},
series: [{
data: [[10,10],[20,20],[30,15],[40,10],[50,20],[60,15],],
type: "line",
}]
});
chart.setOption({
...chart.getOption(),
series: [{
data: [[10,10],[20,20],[30,15],[40,10],[50,20],[60,15],],
type: "line",
markLine: {
data: [{ xAxis: 15 }, { xAxis: 25},]
},
}]
});
```
### Current Behavior
The chart is rendered without the marklines

### Expected Behavior
The chart is rendered with the marklines

### Environment
```markdown
- OS: linux
- Browser: firefox 139.0.4
- Framework: react@18
```
### Any additional comments?
Note that in my use case, I am using react.
I am updating the chart from different events.
Each does a `React.useEffect` where they call `setOption` and spread the previous option.
When I inspect the option from `getOption`, it has the desired configuration for the chart. Thus, I expect it render the markline
Contributor guide
Assessment
This issue has not been assessed yet.