import {replaceStringAtIndex} from '@augment-vir/common';
replaceStringAtIndex({original: 'eat the waffles', start: 4, replacement: 'his'}); // outputs `'eat his waffles'`
replaceStringAtIndex({original: 'eat the waffles', start: 4, replacement: 'my', length: 3}); // outputs `'eat my waffles'`
Replaces whatever substring is at the given index in the original string with the new string. Optionally, provide a length of the substring to get replaced.