MCPcopy
hub / github.com/codeforreal1/compressO / pad

Function pad

src/utils/string.ts:41–41  ·  view source on GitHub ↗
(n: number, size = 2)

Source from the content-addressed store, hash-verified

39 )
40
41 const pad = (n: number, size = 2) => n.toString().padStart(size, '0')
42 const hoursPart =
43 (options?.enableHoursWhenZero && hours === 0) || hours !== 0
44 ? `${pad(hours)}:`

Callers 1

formatDurationFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected