Range Chart
Trends
"How wide is the spread?" When a single line lies about your data, draw the band instead. Best case to worst case, the forecast cone, the 5th-to-95th percentile - this shades the whole range per series so uncertainty is something the reader can see, not guess at.
canvas · responsive
The chart above is the same engine in every framework - only the integration code below differs.
Usage
tsx
import { RangeChart } from "@michi-vz/react";
export default () => <RangeChart {...props} />; // props = the chart optionsvue
<script setup>
import { RangeChart } from "@michi-vz/vue";
</script>
<template>
<RangeChart :options="props" />
</template>svelte
<script>
import { rangeChart } from "@michi-vz/svelte";
</script>
<div use:rangeChart={props}></div>ts
// main.ts - register the elements once
import "@michi-vz/angular";
import { applyRangeChartProps } from "@michi-vz/angular";
// component (uses CUSTOM_ELEMENTS_SCHEMA)
// template: <michi-vz-range-chart #c></michi-vz-range-chart>
applyRangeChartProps(this.c.nativeElement, props);html
<script type="module" src="https://cdn.jsdelivr.net/npm/@michi-vz/wc"></script>
<michi-vz-range-chart id="c"></michi-vz-range-chart>
<script>
Object.assign(document.getElementById("c"), props); // dataSet/series, title, …
</script>ts
import { mountRangeChart } from "@michi-vz/core";
const chart = mountRangeChart(el, props);
chart.update(next);
chart.getContext(); // renderer-agnostic, LLM-ready
chart.destroy();API
Props are typed as RangeChartProps in @michi-vz/core. Shared across all charts: width, height, margin, colors / colorsMapping, renderer ("svg" | "canvas"), highlightItems, disabledItems, and the on* callbacks. onChartDataProcessed / getContext() return the renderer-agnostic ChartContext.