I'm trying to put a preload. Currently I have 38 series. and I have a function to generate a preload animation called preload.show () and preload.hide (). When I try to generate my chart I invoke preload.show for animation, and when the animation ends preload.hide() attempt to invoke .
the idea is that the preload is displayed before the chart is ready, but the strange thing is that while charging does not show the preload, the preload is only about one second before finishing the animation. What I can do ?. I can not put my full code, then use it in my business and security policies so I can not do.
In short, the preload is not displayed from the moment I want to create my chart. This in a computer looks good, as I wish. but in This problem occurs in cell.
preload.show(); //I generate the preload.
$('#mychart').highcharts({
chart: {
type: 'bar',
height: height
},
title: {
text: 'Mi Chart'
},
xAxis: {
categories: arrayCategories,
title: {
text: null
},
labels: {
x: -5,
y: -20,
useHTML: true,
formatter: function() {
return "<div class='position'>" +this.value+ "</div>";
}
},
yAxis: {
title: null
},
credits: {
enabled: false
},
tooltip: {
enabled: false,
},
"plotOptions": {
"bar": {
"pointPadding": 0,
"borderWidth": 0
},
series: {
events: {
afterAnimate: function () {
preload.hide();
}
},
align:'right',
borderWidth: 1,
dataLabels: {
enabled: true,
style: {
fontWeight: false,
fontSize: '10px',
},
useHTML: true,
formatter: function() {
return ( this.value);
}
},
cursor: 'pointer',
point: {
events: {
click: function () {
}
}
}
}
},
series: myArray //38 series
});