Hello,
I am requesting to be registered as a PAUSE
contributor. My information is as follows:
name -> Robert Lehr
email -> [EMAIL PROTECTED]
homepage -> none
CPAN ID ? -> BOZZIO
I want to contribute Yet Another template module,
mostly because many colleagues have requested that I
make it available to them. We thought it would be
helpful to make it widely available for additional
feedback.
Name: Text::FastTemplate
DSLI: bdpO
44-chars: Compiles line-oriented templates as Perl
subs
It is only useful in Perl programs that use the same
template several times during the lifetime of its
execution such as Apache/mod_perl (surprise!) or a
server/daemon.
Why another template module? I can describe it best
by explaining why it was ever written, ANOTHER
template module. We didn't want to write another
template module. We set our criteria and looked for a
module that would work for our project. We tried a
couple of the popular modules but abandoned them.
Why?
HTML::Template ?
pros: simple syntax, complete isolation of HTML
from perl code
cons: memory leak, slow
HTML::Mason ?
pros: nice component structure, fast
cons: too easy to mix perl and HTML, too complex
for lame HTML coder
Template ?
pros: could make our own template syntax
cons: too much overhead, too complex, meant too
slow
In the end, we wanted a template that was simple, fast
and completely separated the text template from the
perl code. We got it by using:
+ C-preprocessor line-oriented syntax (SIMPLICITY)
+ converting templates to perl code and compiling
and caching it (SPEED)
Our design gave us two additional benefits that we
hadn't planned:
+ component type flexibility of Mason
+ general text-template capability, not restricted
to HTML
Cordially,
Robert Lehr