JSFiddle - React, Tailwind, and code Playground
by inikolova
HTML
<script src="http://cdn.kendostatic.com/2012.1.322/js/kendo.all.min.js"></script>
<link rel="stylesheet" href="http://cdn.kendostatic.com/2012.1.322/styles/kendo.common.min.css">
<link rel="stylesheet" href="http://cdn.kendostatic.com/2012.1.322/styles/kendo.default.min.css">
<link rel="stylesheet" href="http://cdn.kendostatic.com/2012.1.322/styles/kendo.dataviz.min.css">
<div id="chart"></div>
JavaScript
var data = [
{
value1: 2,
value2: 4},
{
value1: 6,
value2: 2},
{
value1: 4,
value2: 6},
{
value1: 8,
value2: 4}];
function createChart() {
$("#chart").kendoChart({
dataSource: data,
series: [{
type: "column",
field: "value1"
},
{
type: "column",
field: "value2"},
{
type: "line",
field: "value1"
},
{
type: "line",
field: "value2"}
],
valueAxis: [{
title: {
text: "miles"
},
min: 0,
max: 10}],
tooltip: {
visible: true,
template: "#= dataItem.value1 # ------ #= dataItem.value2 #"
},
categoryAxis: {
categories: ["Mon", "Tue", "Wed", "Thu", "Fri"],
axisCrossingValue: [0, 0, 100, 100]
}
});
}
$(document).ready(function() {
setTimeout(function() {
// Initialize the chart with a delay to make sure
// the initial animation is visible
createChart();
}, 400);
});