On Wed, Aug 29, 2007 at 04:19:50PM +0200, ry dahl wrote: > Why not just autoload Haml (or whatever) when it encounters a .haml template? > Perhaps it doesn't do that now but surely this wouldn't be difficult.
Merb doesn't search for filenames ending in .haml unless the Haml extension has been loaded. Old Merb (0.3.7) simply loaded all the template extensions in regardless. Therefore it would always check for .haml, and process it accordingly. Ezra changed this in trunk r401: http://merb.devjavu.com/projects/merb/changeset/401#file18 This doesn't seem to have been fully thought-through, because not loading the Haml template library means that the code that registers '.haml' as a known extension, and associates it with Merb::Template::Haml, is not run. It would make sense if register_engine were called to register .haml outside of Merb::Template::Haml (but register_engine would have to be modified to be passed a symbol, not a class, because referencing the class would cause it to be autoloaded anyway) Regards, Brian. _______________________________________________ Merb-devel mailing list [email protected] http://rubyforge.org/mailman/listinfo/merb-devel
