The template object

The template object has a handful of attributes.

Referencing just template returns the name of the template used to render the current page, with the .liquid extension omitted.

Returns the name of the template's parent directory. Returns nil for templates whose parent directory is the templates/ folder.

Returns the template's name without the template's custom suffix, if it exists, or the .liquid extension.


Returns the name of the custom template without the prefix or the .liquid extension. Returns nil if a custom template is not being used.