[LRUG] Rails : Drying Up Views
Tim Cowlishaw
tim at timcowlishaw.co.uk
Tue Sep 11 09:19:14 PDT 2007
We've spent quite some time developing a framework for UI 'widgets', which
are ruby classes with associated templates, css and javascript files, that
can be instantiated anywhere in the view, across the whole application. I
rather like this approach, as it encourages view code that has a sensible OO
architecture - UI widgets can be subclassed from each other, and can mixin
different interfaces, which saves a lot of repetition of code. We're going
to try to package this framework up as a rails plugin sometime - more
information should be forthcoming at devblog.playlouder.com if you're
interested at some point.
Cheers,
Tim
On 9/11/07, Anthony Green < Anthony.Green at bbc.co.uk> wrote:
>
>
>
> Does anyone have any techniques for sharing view code generators
> (partials, helpers, yielding to content_for) across actions in different
> controllers.
>
> I¹m finding most techniques blogged about only deal with situations where
> there is more commonality between view/actions within a controller than
> view/actions (with the same name) across controllers.
>
>
> --
> Anthony Green
> Client Side Developer - Programme Information Tool
> Audio & Music Interactive
> BBC Future Media & Technology
>
>
>
> http://www.bbc.co.uk/
> This e-mail (and any attachments) is confidential and may contain personal
> views which are not the views of the BBC unless specifically stated.
> If you have received it in error, please delete it from your system.
> Do not use, copy or disclose the information in any way nor act in
> reliance on it and notify the sender immediately.
> Please note that the BBC monitors e-mails sent or received.
> Further communication will signify your consent to this.
>
> _______________________________________________
> Chat mailing list
> Chat at lists.lrug.org
> http://lists.lrug.org/listinfo.cgi/chat-lrug.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lrug.org/pipermail/chat-lrug.org/attachments/20070911/50f3f31a/attachment-0007.html>
More information about the Chat
mailing list