Chart.ReferenceLine

A threshold or target across the plot.

JanFebMarAprMayJun01020304050Target
Chart of Projects published over 6 points
monthProjects published
January24
February31
March28
April35
May42
June38
<Chart.ReferenceLine value={30} label="Target" />

API

PropTypeDefault
valuenumberrequiredPosition on the value axis.
labelstringText drawn beside the line — a target, a threshold, an average.
strokeDasharraystring"4 4"Dash pattern for the line. Pass undefined for solid.

Plus every <g> prop. Source: chart/components/chart-reference-line.tsx.

value is on the value axis, so a reference line marks a threshold, a target or an average — not a date. Place it after the marks to draw it on top.