I am using Highcharts v4.0.3 with exporting.js in my web app, and I want to be able to just provide the end user with the following download options:
You can remove unnecessary options the following way:
if (Highcharts.getOptions().exporting) {
let contextButton = Highcharts.getOptions().exporting.buttons.contextButton;
contextButton.menuItems = contextButton.menuItems.filter((item) => {
return item.textKey === 'downloadJPEG' || item.textKey === 'downloadPNG';
});
}