Live availability
An application example showing current availability states as a complete status snapshot.
Live-data contract
Bar and Line accept an opt-in LiveData source. Each SSE event carries a complete CartesianSnapshot, so reconnects replace stale client state deterministically.
Usage Example
@interactive.Bar(interactive.BarConfig{
Label: "Live availability",
XAxis: rollingCategories, // 36 evenly spaced buckets.
Series: oneHotStateSeries, // Healthy, Degraded, Down; equal lengths.
SeriesOptions: interactive.SeriesOptions{
Stack: "availability", BarWidth: "70%", BarGap: "0%",
},
Options: interactive.ChartOptions{Animation: interactive.Bool(false)},
Live: &interactive.LiveData{URL: "/examples/live-availability/events", Event: "chart"},
})Application semantics
Availability states belong to this example, not the chart taxonomy. Narrow stacked bars express checks while text and legend preserve state meaning without relying on color alone.