code: function createPadding(string, length, chars) {
          length = toInteger(length);
          var strLength = stringSize(string);
          if (!length || strLength >= length) {
            return '';
          }
          var padLength = length - strLength;
          chars = chars === undefined ? ' ' : chars + '';
          var result = repeat(chars, nativeCeil(padLength / stringSize(chars)));
          return reHasComplexSymbol.test(chars) ? stringToArray(result).slice(0, padLength).join('') : result.slice(0, padLength);
        }
docs: Creates the padding for `string` based on `length`. The `chars` string
  is truncated if the number of characters exceeds `length`.
  
  @private
  @param {string} string The string to create padding for.
  @param {number} [length=0] The padding length.
  @param {string} [chars=' '] The string used as padding.
  @returns {string} Returns the padding for `string`.