label: String

Sets the label of the stripLine. These are shown on top of axis labels.

Default: “” (empty string)
Example: “Threshold”, “1920”
var  chart =  new  CanvasJS.Chart("container",
{
 .
 .
axisY:{
    stripLines: [{
        .
        label:"Label 1",
        .
    }]
},
 .
 .
});
chart.render();

Try Editing The Code


If you have any questions, please feel free to ask in our forums.Ask Question

2 Comments

  1. Sebastian says:

    Hi, is there any opportunity to have the stripLine-label not on top of the y-axis-label?
    For example, when I’m changing on the above example the value from 35 to 40, the label “35” is hiding the value 40. I want to display both of them.
    Is this somehow possible? Like having the stripLine-label left of the axis-label?
    Thanks.

    • Anjali says:

      Sorry, this feature is not available yet but we are considering the same for future versions.

If you have any questions, please feel free to ask in our forums. Ask Question