How can I replace a substring of a string given the starting position and the length?
I was hoping for something like this:
var string = "This is a test string";
string.replace(10, 4, "replacement");
so that string
would equal
"this is a replacement string"
..but I can't find anything like that.
Any help appreciated.