RubyFrontier Documentation

The Template

As I have said about a zillion times already, when RubyFrontier processes a renderable page object, it will attempt to embed such an object into a template. I have already shown you a screen shot of the same page object passed through three different templates, to give you the general idea.

The template is usually how a Web page gets its overall appearance. A template can contain literal HTML as well as macro calls, and it usually contains both. In particular, it usually determines what goes in the document’s <head> area (including its CSS) as well as common content such as unifying navigation to appear on multiple pages.

Thus, you need to know how the template is located and how this insertion is performed.

How the Template is Located

The template associated with any given renderable page object can either be a directive object or specified through a scalar directive.

What’s in a Template

A template is a flexible beast, but certain features of templates are quite common, so here is a quick guide.

Next: Macros and Macro Scoping

This documentation prepared by Matt Neuburg, phd = matt at tidbits dot com (, using RubyFrontier.
Download RubyFrontier from GitHub.