instance method String#capitalize
String#capitalize() → String
Capitalizes the first letter of a string and downcases all the others.
Examples
'hello'.capitalize(); // -> 'Hello' 'HELLO WORLD!'.capitalize(); // -> 'Hello world!'
String#capitalize() → String
Capitalizes the first letter of a string and downcases all the others.
'hello'.capitalize(); // -> 'Hello' 'HELLO WORLD!'.capitalize(); // -> 'Hello world!'