strOutput.replace(\"/{{[^]*?}}/g\",\"\");
Is there a way to convert JavaScript regexes to Java-safe regexes?
The above statement gives me t
Get rid of "/" and "/g" at the start and the end of regex. Then you need to escape every "\" occurrence like so: "\\".
"/"
"/g"
"\"
"\\"
The "g" part means global. This is controlled in how you use regex in Java as opposed to in the regex string.