how to replace a certain element in a string in js code example
Example: replace all character in string javascript
let a = "How to search and replace a char in a string";
while (a.search(" ", ""))
{
a = a.replace(" ", "");
}
console.log(a);
let a = "How to search and replace a char in a string";
while (a.search(" ", ""))
{
a = a.replace(" ", "");
}
console.log(a);