legendMarkerType: String

Sets the Legend Marker to one of the options below. This property is used to override the default marker in legend, which is same as dataSeries Marker Type.

Default: same as markerType
Options: “circle”, “square”, “cross” and “triangle”
Note
  • To disable marker inside legend, set legendMarkerType to “none”
var  chart =  new  CanvasJS.Chart("container",
{
 .
 .
 data:[{
  legendMarkerType: "square",

  },
 ]
 .
 .
});
chart.render();

Try Editing The Code


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