-
-
Couldn't load subscription status.
- Fork 1.4k
Description
Description
When datalabels are enabled it seems that even returning an empty string value or undefined from the formatter function renders empty <text> nodes which affects performance. It seems that we have to completely disable datalabels when there are quite a few data points. I only noticed this because I saw a console warning being printed about there being too many datalabels. Also it seems that I could get rid of the warning by simply setting the maxItems to equal the length of the data points in the series but I don't want to do that. I would not like the <text> nodes to render at all if the formatter returns undefined or empty string value (but ok to render if 0 is returned since it is a valid label value.) I would also be ok if it didn't render only if undefined is returned which is not the case as I tried that too.
Steps to Reproduce
- Create a column chart (bar) with at least 200 data points
- Enable data labels via
dataLabels.enabledproperty - Warning is printed in the console
Expected Behavior
Empty text nodes are not rendered.
Actual Behavior
Empty text nodes are rendered.
Screenshots
N/A