(n: number)
| 89 | } |
| 90 | |
| 91 | function formatNumber(n: number): string { |
| 92 | if (n >= 1000) { |
| 93 | // Format with underscores for readability (e.g., 131_072) |
| 94 | return n.toString().replace(/\B(?=(\d{3})+(?!\d))/g, "_"); |
| 95 | } |
| 96 | return n.toString(); |
| 97 | } |
| 98 | |
| 99 | function timestampToDate(timestamp: number): string { |
| 100 | const date = new Date(timestamp * 1000); |
no outgoing calls
no test coverage detected