Javascript Replace String in String
By Forrest Smith - Drempd.com
let text = "The dogs barked loudly";
let result = text.replace("dogs", "cats");
Replace all instances:
let text = "The dogs barked loudly";
let result = text.replace("dogs/g", "cats");
-
Adventure
-
The Built Environment
-
Locations
-
Web Dev