I would like to be able to change the numbers into dollars with commas. For example, 10000 into $10,000.
I would like this for 1) the tooltip numbers and 2) xAxis values.
Here are links to the graph thus far:
https://codepen.io/JamesDraper/pen/PXgLre or https://syncfiddle.net/fiddle/-LWPx0qe1VWChvodRlGC
Edit: I have updated the links with the code suggested by users.
This graph is quite large and it contains about 50 hours of legal research.
var myChart = new Chart(ctx, {
          type: 'horizontalBar',
          data: {
            labels: years,
            datasets: [
              {
                data: number,
                label: "Amount of Compensation",
                fill: true,
                backgroundColor: 'rgba(83, 19, 30, 1)',
              },
            ]
          },
          options: {
            scales: {
                yAxes: [{
                    ticks: {
                        fontSize: 9,
                      }
                    }],
                xAxes: [{
                   ticks: {
                       // Include a dollar sign in the ticks
                       callback: function(value, index, values) {
                           return '$' + value;
                       }
                   },
               }],
            }
        },
    });
 
    