MCPcopy Create free account
hub / github.com/devaccuracy/ledgerforge / formatCompact

Function formatCompact

tests/loadtest/tools/dashboard/app.js:1399–1407  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

1397}
1398
1399function formatCompact(value) {
1400 if (value === null || value === undefined) {
1401 return "n/a";
1402 }
1403 return new Intl.NumberFormat(undefined, {
1404 notation: value >= 10000 ? "compact" : "standard",
1405 maximumFractionDigits: value >= 100 ? 0 : 2,
1406 }).format(value);
1407}
1408
1409function formatRate(value) {
1410 return value === null || value === undefined ? "n/a" : `${formatCompact(value)}/sec`;

Callers 6

renderSummaryGridFunction · 0.85
renderChecksFunction · 0.85
buildStatsFunction · 0.85
formatThresholdValueFunction · 0.85
formatRateFunction · 0.85
formatTpmFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected