Removes ANSI color codes and movement commands.

ParameterTypeRequiredDefaultDescription
asstringoptional[a]  Name of output field, default is to replace contents of input field.
field[b]stringrequired@rawstring Specifies the field where to remove ANSI escape codes.

[a] Optional parameters use their default value unless explicitly set

[b] The argument name field can be omitted.

Omitted Argument Names

The argument name for field can be omitted; the following forms of this function are equivalent:

logscale
stripAnsiCodes("@rawstring")

and:

logscale
stripAnsiCodes(field="@rawstring")

Remove the ANSI escape codes from the message field.

logscale
message := "\x1b[93;41mColor"
| stripAnsiCodes(message)
| @display := message

Remove all ANSI escape codes from @rawstring

logscale
stripAnsiCodes()