Provides access to general information regarding navigation around a page including parent pages, children, breadcrumbs, level, etc.
Returns the children of the page as a hash.
{{ page.children }}
{% if page.has_children? %}
This page has {{ page.children.length }} sub-pages.
{% endif %}
Returns true if the page has any sub-pages (whether or they be hidden).
{% if page.has_children? %}
This page has sub-pages.
{% endif %}
Returns true if the page has a parent page.
{% if page.has_parent? %}
This page has a parent-page.
{% endif %}
Returns true if the page has any visible sub-pages.
{% if page.has_visible_children? %}
This page has visible sub-pages.
{% endif %}
Returns true if the page is a root page.
{% if page.root? %}
This is the root page.
{% endif %}
Returns the depth of the page in the navigation.
{{ page.level }}
Returns the next page. The last page returns itself.
{{ page.next_page }}
<a href="{{page.next_page}}">Go to next page</a>
Returns the parent-page.
{{ page.parent }}
<a href="{{ page.parent.url }}">Parent</a>
Returns the previous page. The first page returns itself.
{{ page.previous_page }}
<a href="{{ page.previous_page }}">Go to previous page</a>
Returns the sub-pages of the page which are visible as a hash.
{{ page.visible_children }}
{% if page.has_visible_children? %}
This page has {{ page.visible_children.length }} subpages.
{% endif %}
Returns the root ancestor of the page.
{{ page.root }}
<a href="{{ page.root.url }}">
Go back to {{ page.root.name }}
</a>