Stop chart dynamicChartOptions array growing unrestricted#2013
Stop chart dynamicChartOptions array growing unrestricted#2013
dynamicChartOptions array growing unrestricted#2013Conversation
|
@colinl - does this make sense to you? See any issues with consolidating the chart options? |
|
It is difficult for me to see the complete picture as I only have a phone. |
The array is still present and does get populated so long as there is no chart object. Once there is a chart object, the changes should be applied and consolidated. That's the theory anyhow. I don't have time to dig further and do any manual testing so this will sit here for a while Colin. |
|
Looking at this again I agree that it would be an improvement, but it does not fix the underlying problem as the array will still build up if the chart is not on screen. I did it this way, though I was not really happy with it, in order to avoid having to import a deep merge package such as lodash.merge. Having thought about it again, I wonder whether a better solution would be, when msg.ui_update.chartOptions is passed to the node, to perform the deep merge server side, as is done at the moment, but then always pass the full merged set to the clients, rather than just the latest modification. The clients would then only need to save the latest set. There would be a small increase in comms, but only when chartOptions is passed to the node, but I can't see that it would ever be significant. |
Description
Consolidates dynamicChartOptions array into a singular row by calling
this.chart.getOption()Related Issue(s)
closes #2012
Checklist
flowforge.yml?FlowFuse/helmto update ConfigMap TemplateFlowFuse/CloudProjectto update values for Staging/ProductionLabels
area:migrationlabel