MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / compact

Function compact

telemetry-dashboard/public/theme.js:84–87  ·  view source on GitHub ↗
(n)

Source from the content-addressed store, hash-verified

82
83/** Stat-tile values: 1,284 stays exact; 12,900 becomes 12.9K. */
84export function compact(n) {
85 if (n === null || n === undefined || Number.isNaN(n)) return '—';
86 return Math.abs(n) >= 10_000 ? COMPACT.format(n) : PLAIN.format(n);
87}
88
89export function number(n) {
90 if (n === null || n === undefined || Number.isNaN(n)) return '—';

Callers 1

panels.jsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected