Implement a camelCaseKeys function
camelCase
is a convention used in programming and naming conventions where multiple words are
combined into one continuous string of text, with each word within the string capitalized except for the first word.
camelCase
conventions are followed in JavaScript codebases as well. We need to implement a
camelCaseKeys functon that can convert all keys in object to follow camelCase convention.
1. Basic implementation
Input can have nested objects or array of objects. Try not to mutate the original input.
Here the implementation of camelCase
is not really important. You can use any technique solution you prefer present on the internet. The goal is not to focus on utility but rather the recursion done.
Further Reading
I strongly encourage you to explore and tackle additional questions in my Recursion Questions for Frontend Interviews blog series.
By doing so, you can enhance your understanding and proficiency with recursion, preparing you to excel in your upcoming frontend interviews.
Wishing you best. Happy Interviewing 🫡.