mirror of
https://github.com/zeromicro/go-zero.git
synced 2025-01-24 01:30:25 +08:00
11 lines
172 B
Go
11 lines
172 B
Go
|
package timex
|
||
|
|
||
|
import (
|
||
|
"fmt"
|
||
|
"time"
|
||
|
)
|
||
|
|
||
|
func ReprOfDuration(duration time.Duration) string {
|
||
|
return fmt.Sprintf("%.1fms", float32(duration)/float32(time.Millisecond))
|
||
|
}
|