const html =
`<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<canvas id="myChart"></canvas>
<script>
new Chart("myChart", {
type: "bar",
data: {
labels: [${device}],
datasets: [{
backgroundColor:[${color}],
data:[${value}]
}]
},
options: {
legend: {display: false},
title: {
display: true,
text: "World Wine Production 2018"
}
}
});
</script>
</body>
</html>`;
When I initially ran it with fixed labels, backgroundColor, data it works how ever when I
replace them with the the variables i gotten from the device, the pdf just shows all blanks.
I am not sure if it is the issue with the array and string I passed in or is it unable to
check the variables