reverse
Reverse the order of all elements in an array, returning a reversed collection.
Syntax
{{ array | reverse }}Example
{% assign steps = "Intake,Review,Approved" | split: "," %}{{ steps | reverse | join: " - " }}Output
Approved - Review - IntakeThe reverse filter inverts the sequence of elements across an array, placing the last item first and the first item last. It operates on array copies, leaving underlying source collections unmodified.
On programmatic landing pages, reverse changes the display order of chronological milestones or geographic breadcrumbs. For example, reversing hierarchical paths from county-city-neighborhood into neighborhood-first focus: {{ row.breadcrumbs | split: '/' | reverse | join: ' · ' }}. This immediately highlights local neighborhood relevance to mobile search visitors.
Filters
- abs
- append
- at_least
- at_most
- capitalize
- ceil
- compact
- concat
- date
- default
- divided_by
- downcase
- escape
- escape_once
- first
- floor
- join
- last
- lstrip
- map
- minus
- modulo
- newline_to_br
- plus
- prepend
- remove
- remove_first
- replace
- replace_first
- reverse
- round
- rstrip
- size
- slice
- sort
- sort_natural
- split
- strip
- strip_html
- strip_newlines
- times
- truncate
- truncatewords
- uniq
- upcase
- url_decode
- url_encode
- where
- raw
- slugify
- number_format
