replace string in typescript

Solutions on MaxInterview for replace string in typescript by the best coders in the world

showing results for - "replace string in typescript"
Rebeca
27 Feb 2017
1var re = /apples/gi; 
2var str = "Apples are round, and apples are juicy.";
3var newstr = str.replace(re, "oranges"); 
4console.log(newstr)