[PEPr] Comment on HTML::Template_Savant

From: Date: Wed, 02 Jun 2004 12:35:30 +0000
Subject: [PEPr] Comment on HTML::Template_Savant
Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-29862@lists.php.net to get a copy of this message
Greg Beaver (http://pear.php.net/user/cellog) has commented on the proposal for HTML::Template_Savant. Comment: I'd like to point out that Paul's API decisions were very clearly structured around what his users wanted. Although we tend not to acknowledge this fact, Smarty is the only template engine that about 90% of PHP users use. Paul's API is compatible with the Smarty engine. I don't see anything stupid or disrespectful about that choice. Those of you who use template engines only for web pages probably don't see the reason for a non-compiling template engine, but then again, none of you have coded a large-scale application like phpDocumentor. Redistributing compiled templates is a complete nightmare. 1) compilation by definition interprets what you've done, so templates often behave differently than you think they will. The process of learning a new template language causes countless bugs still to this day in phpDocumentor templates 2) if you forget to compile a template, your application doesn't work in a shared environment because users don't have write access to the compiled templates directory. 3) doing anything meaningful in a template language requires tremendous power, and the complexity of a template becomes extremely difficult to debug or maintain, as the language is usually limited for security reasons. These three headaches have caused endless annoyance for phpDocumentor development. Personally, I don't think the Smarty-esque filtering code is all that necessary, and might implement a few features differently from Paul, but the crisis over having Savant in PEAR at all doesn't make much sense to me. However, I should add that I do like the direction Alan is taking Flexy with the recent commits, this seems a good decision, one that other template engines could learn from. Supporting competing APIs and features is always a good thing. I didn't mean to single Savant out with my last comments about supporting competing APIs - this is something all competing packages should do. Simpletest is another example of a great package that supports competing APIs. Any other propietary API design is too close to Microsoft for my tastes :) Proposal information: http://pear.php.net/pepr/pepr-proposal-show.php?id=83 -- Sent by PEPr, the automatic proposal system at http://pear.php.net

« previous php.pear.dev (#29862) next »