2018-04-02 07:34:16 +02:00

3 lines
165 B
TypeScript

export function plural(count: number, singular: string): string {
return (count === 1 || count === -1) ? (count + " " + singular) : (count + " " + singular + "s")
}