code: function (str) {
              if (str.length > 0) {
                  var first = str.substr(0, 1).toUpperCase();
                  var spare = str.substr(1, str.length);
                  return first + spare;
              }
          }
docs: 首字母大写