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
x
1
anychart.onDocumentReady(function () {
2
// To work with the data adapter you need to reference the data adapter script file from AnyChart CDN
3
// (https://cdn.anychart.com/releases/8.13.0/js/anychart-data-adapter.min.js for latest or https://cdn.anychart.com/releases/8.13.0/js/anychart-data-adapter.min.js for the versioned file)
4
5
// Create a chart by JSON config.
6
anychart.fromJsonFile('https://cdn.anychart.com/config-samples/line-chart.json', function (chart) {
7
chart.title('Create a chart by JSON config');
8
chart.container('container');
9
chart.draw();
10
});
11
});