Update dist/index.js

This commit is contained in:
Michal Dorner 2021-01-29 01:04:01 +01:00
parent c75a9dd8c8
commit 07a0223ee3
No known key found for this signature in database
GPG key ID: 9EEE04B48DA36786
4 changed files with 117 additions and 75 deletions

View file

@ -39,7 +39,7 @@ export function ellipsis(text: string, maxLength: number): string {
return text.substr(0, maxLength - 3) + '...'
}
export function formatTime(ms: number) {
export function formatTime(ms: number): string {
if (ms > 1000) {
return `${(ms / 1000).toFixed(3)}s`
}