mirror of
https://github.com/CompassConnections/Compass.git
synced 2026-04-07 08:15:52 -04:00
7 lines
217 B
TypeScript
7 lines
217 B
TypeScript
/**
|
|
* Returns the possessive form of a name.
|
|
* Adds 's unless the name already ends with s, in which case just adds '.
|
|
*/
|
|
export const possessive = (name: string) =>
|
|
name.endsWith('s') ? `${name}'` : `${name}'s`
|