9951 explained code solutions for 126 technologies


chart.jsSet line chart line color


new Chart('chart', {
  // ...
  data: {
    datasets: [{ data: [1, 2, 3], borderColor: '#0ac282' }]
  }
});ctrl + c
'chart'

id of canvas element

data: [1, 2, 3]

example dataset

borderColor: '#0ac282'

change line color to green