pub fn max(
state: &State<'_, '_>,
value: Value,
kwargs: Kwargs,
) -> Result<Value, Error>Expand description
Returns the largest item from an iterable.
The filter accepts a few keyword arguments:
case_sensitive: set totrueto compare strings case sensitively.attribute: can be set to an attribute or dotted path to compare by that attribute. The whole item is returned.
{{ [1, 2, 3, 4]|max }} -> 4
{{ users|max(attribute="age") }}