HTMLcopy
1
<div id="container"></div>
CSScopy
6
1
html, body, #container {
2
width: 100%;
3
height: 100%;
4
margin: 0;
5
padding: 0;
6
}
JavaScriptcopy
10
1
anychart.onDocumentReady(function () {
2
var chart = anychart.bar();
3
var series = chart.bar([2, 8, 4, 10]);
4
series.labels({
5
fontSize: "14px",
6
position: anychart.enums.Position.CENTER // set position for label.
7
});
8
chart.container("container");
9
chart.draw();
10
});