> Cool, José. I started working on decoupling rendering and controller. > For instance, AV::Renderer and friends shouldn't need a controller > instance. However, PartialRenderer relies on the controller - I don't > see the point why the PartialRenderer is responsible for finding a > template. Isn't that a concern for the LookupContext? I'd love to see > the *Renderer being Renderer and nothing more. Any thoughts on this?
The PartialRenderer (or any renderer) is not really finding the template but it is simply preparing all the options that are used when finding the template. To prepare those options, it needs the controller. It should not be hard to decouple these two as the PartialRenderer only needs the class and prefixes from the controller. The prefixes could be stored in the lookup context object (as they are per se lookup information) and I believe the class could be swapped by "prefixes.first". > In addition, is there any interesting in restructuring the view tests? > I'd move things and make it more obvious where to find what. It is ok to restructure if we have clear benefits. I believe making "more obvious where to find what" is somehow subjective. :) -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
