MCPcopy Create free account
hub / github.com/arctic-cli/interface / number

Function number

packages/arctic/src/util/locale.ts:31–38  ·  view source on GitHub ↗
(num: number)

Source from the content-addressed store, hash-verified

29 }
30
31 export function number(num: number): string {
32 if (num >= 1000000) {
33 return (num / 1000000).toFixed(1) + "M"
34 } else if (num >= 1000) {
35 return (num / 1000).toFixed(1) + "K"
36 }
37 return num.toString()
38 }
39
40 export function duration(input: number) {
41 if (input < 1000) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected