Created
July 8, 2014 23:21
-
-
Save jronal/64778b4063c89be3944d to your computer and use it in GitHub Desktop.
convert underscore to camelCase
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
| var camelCase = string.replace(/_([a-z])/g, function (g) { return g[1].toUpperCase(); }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment