I want to do a string replacement in a prerule block using regular expressions. I know there is a function, but I can not find it. Tips
I think something like this:
origStr = "Original-string-has-hyphens";
newStr = origStr.replace(re/-/ /g);
Result: newStr = "Original string has hyphens".
EDIT: I just realized that a few years ago I asked a similar question , but I never had a working answer.
source
share