repeat
_.repeat(n, string)
# Ⓢ [Ⓣ][1] Ⓝ
Repeats the given string n times.
Since
3.0.0
Arguments
n(number): The number of times to repeat the string.string(string): The string to repeat.
Returns
(string): Returns the repeated string.
Example
_.repeat(3, '*');
// => '***'
_.repeat(2, 'abc');
// => 'abcabc'
_.repeat(0, 'abc');
// => ''