Created
December 27, 2015 12:18
-
-
Save gerzhan/8d1724f5d269fbe1ccda to your computer and use it in GitHub Desktop.
To Camel Case build
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function toCamelCase(str) { | |
return str.replace(/[_-][a-z]/ig, function (s) { | |
return s.substring(1).toUpperCase(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment