How to repeat a string in JavaScript

Strings
By Jad Joubran · 
Last updated Aug 16, 2020
const string = "Code";

string.repeat(3);
"CodeCodeCode"
String.repeat on MDN