如果使用[Underscore.js][1]或[Lodash][2],[underline.string][3]库提供字符串扩展名,包括大写:>_.caprize(string)将字符串的第一个字母转换为>大写。例子:_.capitalize(“foo bar”)==“foo bar”[1]: http://underscorejs.org/[2]: http://lodash.com/[3]: https://github.com/epeli/underscore.string