tdreyno/middleman — Issue #207: Implement sitemap traversal (parent & children helpers)
Author: tdreyno
Created: 2011-12-22 07:56:20+00:00
State: open
Labels: Feature Request

On any template, the `page` method will return the `Sitemap::Page` instance of the current page.

This instance will have `source_file`, `data`, `parent` and `children` methods.

`source_file` returns the source. So if the current page is "/index.html" then the `source_file` is `source/index.html.erb`

`data` returns the frontmatter

`parent` returns the parent page, which is a non-building page representing the folder

`children` returns all child pages of a folder