On 29/08/2007, at 5:06 PM, Brian Candler wrote: > On Wed, Aug 29, 2007 at 06:38:48AM +0100, Brian Candler wrote: >> You just need to reference the class in merb_init.rb to trigger the >> autoload, e.g. >> >> Merb::Template::Haml >> >>> So the question is: >>> >>> * Is this the permanent situation for the future? > > On reflection, it doesn't seem to make much sense to set up > autoloading, but > then to have to explicitly trigger it. Based on the Merb KISS > principle, I > think it would be cleaner to just put > > require 'merb/template/haml' > > in merb_init.rb, and get rid of the autoload magic (although > there's only a > tiny bit of that, in lib/merb/template.rb) > > Does anyone else share this opinion?
I agree with that. Merb's mantra should be 'less magic'. That said I'm not so sure about requiring vs. having an actual method for loading the template engine. Then in the future the templating code can me moved about without disturbing users. Also requiring like that means the code will be pulled in via a gem right? A method for loading the template classes would allow users to stash Merb in the framework directory without having to change the path used in the require. how about something like: templating :erubis Just a thought :) -- Luke _______________________________________________ Merb-devel mailing list [email protected] http://rubyforge.org/mailman/listinfo/merb-devel
