MCPcopy Create free account
hub / github.com/GCWing/BitFun / optionalRounded

Function optionalRounded

src/web-ui/src/shared/utils/startupTrace.ts:178–182  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

176}
177
178function optionalRounded(value: unknown): number | undefined {
179 return typeof value === 'number' && Number.isFinite(value)
180 ? roundDurationMs(value)
181 : undefined;
182}
183
184function optionalString(value: unknown): string | undefined {
185 return typeof value === 'string' && value.length > 0 ? value : undefined;

Callers 2

recordApiCallMethod · 0.85
recordReactRenderProfileFunction · 0.85

Calls 1

roundDurationMsFunction · 0.90

Tested by

no test coverage detected