docs: function truncate(string, length, end) {
      var ret = string;
      if (comb.isString(ret)) {
          if (string.length > length) {
              if (end) {
                  var l = string.length;
                  ret = string.substring(l - length, l);
              } else {
                  ret = string.substring(0, length);
              }
          }
      } else {
          ret = truncate("" + ret, length);
      }
      return ret;
  }