Javascript String Replace Sub String vs Replace Word
let myString = "Both Java and JavaScript."; console.log( myString.replace("Java", "X")); console.log( myString.replace(/Java/g, "X"));