I am trying to make a nice infographic which shows different numbers per month. Since I thought it’d be the easiest way of doing it I picked chart.js, and created with it this short code:
<canvas id="myChart"></canvas>
<script src="https:// cdn.jsdelivr .net/npm/chart.js@2.8.0"></script>
<script>
var ctx = document.getElementById('myChart').getContext('2d');
var chart = new Chart(ctx, {
// The type of chart we want to create
type: 'line',
// The data for our dataset
data: {
labels: ['January', 'February', 'March', 'April', 'May', 'June', 'July'],
datasets: [{
label: 'My First dataset',
backgroundColor: 'rgb(255, 99, 132)',
borderColor: 'rgb(255, 99, 132)',
data: [0, 10, 5, 2, 20, 30, 5]
}]
},
// Configuration options go here
options: {}
});
</script>
I pasted it into an HTML Iframe and it works, but only static. I’m trying to get the ‘Data’ to be changed through Corvid.
How can I do this?
Thanks.