axisDefaults.lineObject

The configuration of the axis lines. Also affects the major and minor ticks, but not the grid lines.

Example - configure the axisDefaults line

<div id="chart"></div>
<script>
$("#chart").kendoChart({
  axisDefaults: {
    line: {
      color: "red",
      width: 3
    }
  },
  series: [
    { data: [1, 2, 3] }
  ]
});
</script>

axisDefaults.line.colorString(default: "black")

The color of the lines. Accepts a valid CSS color string, including hex and rgb.

Setting the color option affects the major and minor ticks, but not the grid lines.

Example - set the axisDefaults line color

<div id="chart"></div>
<script>
$("#chart").kendoChart({
  axisDefaults: {
    line: {
      color: "blue"
    }
  },
  series: [
    { data: [1, 2, 3] }
  ]
});
</script>

axisDefaults.line.dashTypeString(default: "solid")

The dash type of the line.

The following dash types are supported:

  • "dash" - a line consisting of dashes
  • "dashDot" - a line consisting of a repeating pattern of dash-dot
  • "dot" - a line consisting of dots
  • "longDash" - a line consisting of a repeating pattern of long-dash
  • "longDashDot" - a line consisting of a repeating pattern of long-dash-dot
  • "longDashDotDot" - a line consisting of a repeating pattern of long-dash-dot-dot
  • "solid" - a solid line

Example - set the axisDefaults line dash type

<div id="chart"></div>
<script>
$("#chart").kendoChart({
  axisDefaults: {
    line: {
      dashType: "dash"
    }
  },
  series: [
    { data: [1, 2, 3] }
  ]
});
</script>

axisDefaults.line.visibleBoolean(default: true)

If set to true the chart will display the axis lines. By default the axis lines are visible.

Example - hide the axisDefaults line

<div id="chart"></div>
<script>
$("#chart").kendoChart({
  axisDefaults: {
    line: {
      visible: false
    }
  },
  series: [
    { data: [1, 2, 3] }
  ]
});
</script>

axisDefaults.line.widthNumber(default: 1)

The width of the line in pixels. Also affects the major and minor ticks, but not the grid lines.

Example - set the axisDefaults line width

<div id="chart"></div>
<script>
$("#chart").kendoChart({
  axisDefaults: {
    line: {
      width: 3
    }
  },
  series: [
    { data: [1, 2, 3] }
  ]
});
</script>