MCPcopy Index your code
hub / github.com/ChartGPU/ChartGPU / formatDataRate

Function formatDataRate

examples/worker-streaming/main.ts:52–55  ·  view source on GitHub ↗
(bytesPerSec: number)

Source from the content-addressed store, hash-verified

50 new Intl.NumberFormat(undefined).format(Math.max(0, Math.floor(n)));
51
52const formatDataRate = (bytesPerSec: number): string => {
53 const kbps = bytesPerSec / 1024;
54 return `${kbps.toFixed(0)} KB/s`;
55};
56
57// Streaming configuration
58const POINTS_PER_FRAME = 10_000;

Callers 1

streamFrameFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected