platform.js
function format(string) {
    string = trim(string);
    return /^(?:webOS|i(?:OS|P))/.test(string)
      ? string
      : capitalize(string);
  }
function format(string) {
    string = trim(string);
    return /^(?:webOS|i(?:OS|P))/.test(string)
      ? string
      : capitalize(string);
  }
function format ( string ) { string = trim ( string ) ; return / ^(?:webOS|i(?:OS|P)) / . test ( string ) ? string : capitalize ( string ) ; }
Trim and conditionally capitalize string values.

@private
@param {string} string The string to format.
@returns {string} The formatted string.
Trim and conditionally capitalize string values .