fivem-ts

a library to speed up the development of Fivem scripts and frameworks


Project maintained by Purpose-Dev Hosted on GitHub Pages — Theme by mattgraham

fivem-ts - Documentation v0.7.5Docs


fivem-ts - Documentation v0.7.5 / Shared / capitalizeWords

Function: capitalizeWords()

capitalizeWords(input): string

Capitalizes the first letter of each word in a sentence.

Parameters

input: string

The input string where each word’s first letter will be capitalized.

Returns

string

The string with each word’s first letter capitalized.

Example

const result = capitalizeWords("hello world");
console.log(result); // "Hello World"

Defined in

shared/utils/FString.ts:152