@shadab101 wrote:
plz help im stack
showChart3() {
this.emptyspace = 100 - this.value
console.log(this.emptyspace,‘emptyspace’)
var charts = new Chart(document.getElementById(“doughnut-chart”), {
type: ‘doughnut’,
data: {datasets: [ { label: "", backgroundColor: [ "#CC0033", "#D98880" ], data: [this.value, this.emptyspace], hoverBackgroundColor: "#CC0033", } ], allLabelss: [{ text: "This is chart title", align: "center", bold: true, y: 220 }, { text: "Ans here's the subtitle as well", align: "center", bold: false, y: 250 }], }, options: { title: { display: true, text: 'water' } } });console.log(charts)
}
Posts: 2
Participants: 2