FilterParametersExampleThis example…Converts…To…Notes
upper(none)TextVar | upperFormats TextVar in all upper casetexttextConverts any text value to all upper case
lower(none)TextVar | lowerFormats TextVar in all lower casetexttextConverts any text value to all lower case
initcapforceLower: optional true/falseTextVar | initcapCapitalizes the first letter of TextVar, and leaves the rest as-istexttextCapitalizes the first letter of a text value. If :true is specified, the rest of the letters are forced to lower case (otherwise they are left as-is)
titlecapsforceLower: optional true/falseTextVar | titlecaps : trueCapitalizes the first letter of each word in TextVar, and forces the rest to lower casetexttextCapitalizes the first letter of each word in a text value. If :true is specified, the rest of the letters are forced to lower case (otherwise they are left as-is)
formatformatStr: text stringDateVar | format: "DD MMM YYYY"Formats DateVar like "09 JUN 2019"datetextFormats a date according to a format string as defined here: https://date-fns.org/v1.30.1/docs/format
formatformatStr: text stringNumVar | format: "0,0"Formats NumVar like "9,999"numbertextFormats a number according to a format string as defined here: http://numeraljs.com/#format
cardinal(none)NumVar | cardinalSpells a cardinal number (in English), like "nine"numbertext
ordinal(none)NumVar | ordinalSpells an ordinal number (in English), like "ninth"numbertext
ordsuffix(none)NumVar | ordsuffixIf NumVar is 1, this produces "st"numbertextReturns the ordinal suffix appropriate for the given number: "st", "nd", "rd" or "th"
elsetext stringTextVar | else: "no value supplied"
missing valuetextDoes nothing if it's given a value, but if it's not given a value, it returns whatever text it is supplied with
punctext stringListVar | punc: "1, 2 and 3."if list is ["Hello"] => "Hello."
if list is ["A", "B"] => "A and B."
if list is ["A", "B", "C"] => "A, B and C."
listlistDoes not modify the given list, except that it specifies how that list should be punctuated when repetitions are inserted into a template. If used together with other list filters, punc should be last -- the list will "forget" how it's supposed to be punctuated if it is subsequently filtered.
containstext, number, date, or object valueSelectionList | contains: "value"Determines whether SelectionList contains "value"listtrue/falseListVar can be any list variable -- a text list, selection list, or object list. For object lists, the value you are searching for should be an object in JavaScript syntax:
ObjectList | contains: { FirstName: "John", LastName: "Smith" }
sortexpression (optionally preceded by + or -)
Beneficiaries | sort: +LastName : -FirstNameSort the list of beneficiaries ascending by last name, then (within the same last name) descending by first namelistlistReturns the given list of items in the specified order. You must specify at least one sort criterion, but you may specify as many as necessary.
filtercondition: expressionChildren | filter: Age < 18Filter the list to include only those children whose age is less than 18listlistFilters the given list to include only items that meet some condition
findcondition: expressionParties | find: Role == 'Executor'Find the first item in the list where the value of the Role variable equals "Executor"listvalueFinds the first item in a list that meets some condition. Just like Filter, but it only returns a single value, for times when you only care about that one value.
anycondition: expressionChildren | any: Age < 18Returns true if any (one or more) items in the Children list have an Age less than 18; otherwise returns falselisttrue/falseDetermines whether any item(s) in a list meet a certain condition
everycondition: expressionChildren | every: Age < 18Returns true if every item in the Children list has an Age less than 18; otherwise returns falselisttrue/falseDetermines whether every item in a list meets a certain condition
maptransform: expressionChildren | map: NameProduces a simple list of text values from the "Name" property of each item in the Children listlistlistMaps (transforms) a list of items into a list of something else, by evaluating the given expression for each item in the list, and returning a list of the results
groupkey: expressionChildren | group: date.yearOf(Birth)Produces a list of objects, where each object has a 2 variables: one called _key, which (in this case) will contain birth years, and another called _values, which will be a list of Children born in that birth year.listlist of groupsSubdivides a list of items into a list of groups of items.  Each group is an object with two properties: _key and _values.