Back

Chart.js Example

Copy Below Code View As A Text File Show Text Only Show API Edit Code
                            

<!DOCTYPE html> <html> <script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.5.0/Chart.min.js"></script> <body> <canvas id="myChart" style="width:100%;max-width:600px"></canvas> <script> const xValues = [100, 200, 300, 400, 500, 600, 700, 800, 900, 1000,'1 June']; new Chart("myChart", { type: "line", data: { labels: xValues, datasets: [{ data: [860, 1140, 1060, 1060, 1070, 1110, 1330, 2210, 7830, 2478,2000], borderColor: "red", fill: false }, { data: [1600, 1700, 1700, 1900, 2000, 2700, 4000, 5000, 6000, 7000,2000], borderColor: "green", fill: false }, { data: [300, 700, 2000, 5000, 6000, 4000, 2000, 1000, 200, 100,2000], borderColor: "blue", fill: false }] }, options: { legend: { display: false } } }); </script>