mirror of
https://github.com/linear/linear-release.git
synced 2026-09-14 20:00:10 +08:00
10 lines
271 B
TypeScript
10 lines
271 B
TypeScript
/**
|
|
* Pluralize a word based on the count.
|
|
* @param count - The count of the word.
|
|
* @param word - The word to pluralize.
|
|
* @returns The pluralized word.
|
|
*/
|
|
export function pluralize(count: number, word: string): string {
|
|
return count === 1 ? word : `${word}s`;
|
|
}
|