[JavaScript] Chart.js



Data

labels: ['1회차', '2회차', '3회차', '4회차', '5회차', '6회차', '7회차'],
  datasets: [
    {
      label: 'hotping.com/',
      fill: false,
      lineTension: 0,
      backgroundColor: 'red',
      borderColor: 'red',
      borderCapStyle: 'butt',
      borderDash: [],
      borderDashOffset: 0.0,
      borderJoinStyle: 'miter',
      pointBorderColor: 'red',
      pointBackgroundColor: '#fff',
      pointBorderWidth: 5,
      pointHoverRadius: 5,
      pointHoverBackgroundColor: 'rgba(75,192,192,1)',
      pointHoverBorderColor: 'rgba(220,220,220,1)',
      pointHoverBorderWidth: 2,
      pointRadius: 1,
      pointHitRadius: 10,
      data: [65, 59, 80, 81, 56, 55, 40]
    },
  • labels

    x축

  • label

    그래프 대상

  • fill

    그래프 안을 채울지 여부

  • lineTension

    라인 굴곡

참고 문서

https://codesandbox.io/s/zen-resonance-ef5o6?file=/src/MyChart.js:2380-2659