JSFiddle - React, Tailwind, and code Playground
by HemalathaThanigaivel
HTML
<script src="http://code.highcharts.com/highcharts.js"></script>
<script src="http://code.highcharts.com/stock/modules/exporting.js"></script>
<div id="container" style="height: 400px; min-width: 310px"></div>
JavaScript
$(function () {
/**
* Add custom date formats
*/
Highcharts.dateFormats = {
W: function (t) {
return ((t % 1)*1000).toFixed(0);
}
};
$('#container').highcharts({
legend: {
layout: 'horizontal',
align: 'right',
verticalAlign: 'top',
floating: true,
y: -10
},
xAxis: {
type: 'datetime',
labels: {
// rotation: -60,
// align: 'center',
useHTML: true,
style: {
fontSize: '14px',
fontFamily: 'proxima-nova,helvetica,arial,sans-seri',
whiteSpace: 'nowrap',
paddingLeft: '10px',
paddingRight: '10px',
paddingTop: '10px',
paddingBottom: '10px',
}
},
/* labels: {
formatter: function(){
return Highcharts.dateFormat('%W',this.value) + 'μs';
}
}, */
tickPositions: [0, 0.010, 0.026, 0.039]
},
series: [{
name: 'AAPL',
data: [
[0, 100],
[0.010, 135],
[0.026, 205],
[0.039, 122]
]
}, {
name: 'bbL',
data: [
[0, 100],
[0.010, 135],
[0.026, 205],
[0.039, 122]
]
}]
});
});
let arr = [{a: 1, b: 2}, {a: 1, b: 2}, {a: 1, b: 2}, {a: 1, b: 2}];
console.log(arr.splice(0,1))