skx/templer — pull request #17 by b3 (2014-04-08 22:55:03+00:00)
Title: Added new type of plugin used to filter template.

`HTML::Template` syntax is meant to mimic normal HTML tags. Using text editors
facility (for instance `nxml-mode` in Emacs) to write templates may
be **very** unpleasant because sometimes it *breaks the rule* (consider, the
`` example cited in its man page). Same
trouble arise when one want to validate or test template rendering before
using it.

The solution described in `HTML::Template` documentation (using HTML comments)
does not really fix the problem. `HTML::Template`, however, offers the
possibility to filter template before processing it.

I added a way to use this filtering opportunity by adding a new type of
plugin, called *filter* plugin, mainly based on the way formatter ones are
done. I implemented two basic such plugins which enable to write template file
in more flexible ways (using *shell-like* variable expansion and strict XML
empty-element syntax).

Tests and documentation have been updated accordingly.