Version: v0.7.0 - Beta.  We welcome contributors & feedback.

String.camelCase

camelCase($options = {}) -> string

Description

Convert to camelCase. A word is any substring that is separated by non-alphanumber characters (spaces, punctutation, etc).

Option Value Description
upper true/false First letter is uppercase
'list-of-posts'.camelCase()
//= 'listOfPosts'

'list of posts'.camelCase()
//= 'listOfPosts'

'admin-user'.camelCase(-upper)
//= 'AdminUser'

See Also