(ms?: number)
| 103 | }; |
| 104 | |
| 105 | const formatDuration = (ms?: number): string => { |
| 106 | if (ms === undefined || ms < 0) return '-'; |
| 107 | if (ms < 1000) return `${Math.round(ms)}ms`; |
| 108 | return `${(ms / 1000).toFixed(2)}s`; |
| 109 | }; |
| 110 | |
| 111 | const formatBytes = (bytes?: number): string => { |
| 112 | if (bytes === undefined || bytes < 0) return '-'; |
no outgoing calls
no test coverage detected