Implement a utility function that converts a snake_case
string into camelCase
.
function snakeToCamel(input: string):
_
) followed by a character with the uppercase version of that character.camelCase
, return it unchanged.| Input | Output |
|-------------------|---------------|
| "hello_world"
| "helloWorld"
|
| "convert_me_now"
| "convertMeNow"
|
| "_private_var"
| "privateVar"
|
| "alreadyCamel"
| "alreadyCamel"
|