Features · format

Compact / SI number abbreviations

native

1.2k, 3.4M style

Matrix status native. Verification types · strong. ChartKit option: ChartKitChartSpecV1.axes.y.format.style=compact.

Source: chartkit:packages/core/src/generated/schema.ts:644

ChartKit spec

Passed validate() during npm run matrix:refresh. The SVG is the server render.

Units rose in Q2.Units rose in Q2.40455055Q1Q2
{
  "version": "1",
  "type": "line",
  "data": [
    {
      "quarter": "Q1",
      "units": 40
    },
    {
      "quarter": "Q2",
      "units": 55
    }
  ],
  "encoding": {
    "x": "quarter",
    "y": "units"
  },
  "a11y": {
    "alt": "Units rose in Q2."
  },
  "size": {
    "width": 640,
    "height": 260
  },
  "axes": {
    "y": {
      "format": {
        "style": "compact"
      }
    }
  }
}

Other libraries

Option names are the paths recorded in the matrix. A grep-only cell names the identifier that matched, not a render test. Markdown copy: format.compact.md.

LibraryStatusOptionVerificationSource
Chart.jsmanualPlugin.afterDatasetsDrawmechanism · weakchart.js/dist/types/index.d.ts:1051
RechartsmanualCustomizedmechanism · weakrecharts/types/component/Customized.d.ts:26
Apache EChartsmanualseries.type=custommechanism · weakecharts/types/dist/shared.d.ts:11176
Highchartsnativelang.numericSymbolstypes · stronghighcharts/highcharts.d.ts:12888
Plotly.jsnativelayout.yaxis.exponentformat=SItypes · strongplot-schema.json#layout.layoutAttributes.yaxis.exponentformat
Nivonativegrep: format'.2s'grep · weak@nivo/legends/dist/types/types.d.ts:3
VictorymanualVictoryBarProps.dataComponentmechanism · weakvictory-core/lib/victory-util/common-props.d.ts:9
visxmanualGroupmechanism · weak@visx/group/lib/Group.d.ts:15
ApexChartsunknown—unverified · unknown—
Tremor (npm)unknown—unverified · unknown—
Observable Plotnativegrep: tickFormat'~s'grep · weak@observablehq/plot/src/scales.d.ts:591
Vega-Litenativegrep: format'.2s'grep · weak84: "description"
AG Chartsnativegrep: format'~s'grep · weakag-charts-types/dist/types/src/serverSideRenderingOptions.d.ts:3
amCharts 5nativegrep: bigNumberPrefixesgrep · weak@amcharts/amcharts5/.internal/plugins/json/Classes.d.ts:159
Google Chartsnativegrep: compactNumberFormat pattern 'short'grep · weak@types/google.visualization/index.d.ts:1577
uPlotmanualOptions.hooksmechanism · weakuplot/dist/uPlot.d.ts:394
TradingView Lightweight Chartsmanualgrep: ICustomSeriesPaneViewmechanism · weak1629: addCustomSeries<TData extends CustomData<HorzScaleItem>, TOptions extends CustomSeriesOptions, TPartialOptions extends SeriesPartialOptions<TOptions> = SeriesPartialOptions<TOptions>>(customPaneView
MUI X ChartsmanualChartsContainermechanism · weak@mui/x-charts/ChartsContainer/ChartsContainer.d.mts:34
Mermaid (chart-ish diagrams only)unknown—conflict · unknown—
AntV G2nativegrep: labelFormattergrep · weak@antv/g2/lib/component/legendCategory.d.ts:5