last - Liquid Filter Reference
On this page
Description
Returns the last item of an list.
| Property | Value |
|---|---|
| Return Type | any |
| Category | lists |
Examples
```liquid
{{ “Mary had a little lamb.” | split: “ “ | last }} ```
Output: lamb.
```liquid
{{ an_list | last }} ```
Output: fire
Was this article helpful?
Thanks for your feedback! It helps us improve our docs.