Transforming Data with Filters
Last updated
Was this helpful?
Last updated
Was this helpful?
You can transform an expression by providing one or more filters in the template expression. Filters are provided using the |
pipe operator.
For example, to upper case the pet’s name:
Will produce the following:
Some filters accept arguments. To pass arguments to a filter, include the arguments list in parentheses: filter(arg1, arg2, ...)
Popular transformation filters are:
title
: convert text to Title Case
truncate
: truncate the text with ellipses. For example: @description | truncate(10)
to truncate text to 10 characters.
join
: concatenate values using a separator. For example: @names | join(",")