Function rocket_dyn_templates::minijinja::filters::last

source ·
pub fn last(value: Value) -> Result<Value, Error>
Expand description

Returns the last item from a list.

If the list is empty undefined is returned.

<h2>Most Recent Update</h2>
{% with update = updates|last %}
  <dl>
    <dt>Location
    <dd>{{ update.location }}
    <dt>Status
    <dd>{{ update.status }}
  </dl>
{% endwith %}