strip

Function

ArgDescriptionType
stringThe string to stripstring (required)
prefixThe prefix to stripstring
suffixThe suffix to stripstring

Description

Strip prefix and/or suffix from a string

If neither prefix nor suffix are provided, leading and trailing whitespace is stripped.

Examples

strip(string=">>  lorem ipsum  <<", prefix=">>", suffix="<<") -> "  lorem ipsum  "
strip(string="   lorem ipsum   ") -> "lorem ipsum"