-
.replace method not working
I cannot get the expression to ‘find a character in a string of text and replace it’ to work.
I’ve been combing the web and trying all the examples & I either get a syntax error (invalid or unexpected token) or it doesn’t do anything.
For example: I have a text layer with every character in the alphabet like this…
abcdefghijklmnopqrstuvwxyz
I then apply this expression to the source text…
text.sourceText.replace(/\d/gi, “test”)
then nada. zip. nuthin.
any ideas?