code: function compact(value, keepNewlines) {
    var check = keepNewlines ? / +/g : /\s+/g;
    return value.replace(check, ' ');
  }
docs: Compact the value, replace multiple white spaces and newlines
  with a single white space.
  
  @param {String} value Value to compact
  @param {Boolean} keepNewlines Do not remove newlines
  @return {String} Compacted data
  @api private