-
Notifications
You must be signed in to change notification settings - Fork 19.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
配置项series.data数组里如果同时存在null和对象,将会报错Cannot read property 'selected' of null #14293
Comments
Hi! We've received your issue and please be patient to get responded. 🎉 In the meanwhile, please make sure that you have posted enough image to demo your request. You may also check out the API and chart option to get the answer. If you don't get helped for a long time (over a week) or have an urgent question to ask, you may also send an email to dev@echarts.apache.org. Please attach the issue link if it's a technical question. If you are interested in the project, you may also subscribe our mailing list. Have a nice day! 🍵 |
This issue is labeled with Please have a look at How to debug ECharts if you'd like to give a try. 🤓 |
i will try to pr this issue |
I ran into this issue in 5.x and I believe it's caused by this method of Series.ts
You can see how it fails if rawItem is null because typeof null === 'object'. Using undefined in the value instead of null works for me as workaround. |
Great! Like #14404, y'all got the focus of this error. Any contribution will be much appreciated! |
Version
5.0.2
Steps to reproduce
非连续的折线图/柱状图,在3.x和4.x版本时,
series.data可以用类似[null,{value:3},{value:4},null]这样的数组呈现,而在5.x版本时候必须使用[{value:null},{value:3},{value:4},{value:null}]
否则将会报错Cannot read property 'selected' of null
What is expected?
正常呈现非连续的折线图
What is actually happening?
报错Cannot read property 'selected' of null
The text was updated successfully, but these errors were encountered: