This is available as Str\repeat
in the www repository.
Returns the input string repeated $multiplier
times
namespace HH\Lib\Str;
function repeat(
string $string,
int $multiplier,
): string;
If the multiplier is 0, the empty string will be returned.
string $string
int $multiplier
string