Creates a new String with some or all of the matches of a pattern replaced by a replacement.
The pattern to be matched is specified by the 'pattern' parameter.
The replacement to be set is specified by the 'replacement' parameter.
An optional 'flags' parameter can be set.
expression | replace:pattern:replacement
Where the input expression is a
Number (to be treated as a
pattern is a
the 'replacement' is a
--Note--: The 'pattern' parameter will be converted to a RegExp instance. Make sure to escape the string properly if you are matching for regular expression special characters like parenthesis, brackets etc.