Dynamically change the menu items of the Export menu
Add the ability to dynamically make changes to the MenuItems located in the chart.options.exporting.buttons.contextButton, without having to destroy/recreate the chart, similar to setTitle() and addSeries() ability to dynamically change the titles and data, respectively.
Currently, one can access the array of MenuItems, and one can make changes to the objects themselves, specifically the onclick() function; the function itself is updated.
However, the text/styling, which may also need to be updated, is NOT reflected in the chart unless you destroy and recreate the chart.
Please add some function, perhaps that may accept an array of menuItem objects, that will re-render just the menuItems without having to rerender the entire chart.
-
David Tran commented
You can achieve it by setting chart["cache-highcharts-contextmenu"] to null, it will force the export menu items to redraw.