MCPcopy Create free account
hub / github.com/anomalyco/opencode / formatCount

Function formatCount

packages/web/src/components/share/common.tsx:39–42  ·  view source on GitHub ↗
(value: number, locale: string, singular: string, plural: string)

Source from the content-addressed store, hash-verified

37}
38
39export function formatCount(value: number, locale: string, singular: string, plural: string) {
40 const unit = value === 1 ? singular : plural
41 return `${formatNumber(value, locale)} ${unit}`
42}
43
44interface AnchorProps extends JSX.HTMLAttributes<HTMLDivElement> {
45 id: string

Callers 2

GrepToolFunction · 0.90
GlobToolFunction · 0.90

Calls 1

formatNumberFunction · 0.70

Tested by

no test coverage detected