Skip to main content
Version: Next

toCamelCase

Using

Сonverts a string into camelCase format.

Demo - use JSON
toCamelCase(
)
"anyString"

Arguments

ArgumentTypeDescriptionExample
strstringString"iAmString"
"Text_TEXT"

Returns

string | undefined — String in the format camelCase or undefined if str was not a string

Examples

toCamelCase('some value');
// "someValue"

toCamelCase('ANY_STRING');
// "anyString"

toCamelCase('iLikeShegit');
// "iLikeShegit"

toCamelCase();
// undefined

toCamelCase(55);
// undefined

Resources

📦 Since:1.2.0
📦 Last updated:1.2.0
📦 Available in:1.3.0