Agreed, very elegant solution.

- Matt

On Thu, Feb 16, 2012 at 10:49 AM, Robert Kaufman <[email protected]>wrote:

> I really like this approach.  Which those who have talked JS with me know
> is a rare thing.  You are loading all the JS in one download (good) but
> only taknig up memory for it and loading it when you need it.  Another
> important piece of Rafael's method is that it works equally well if add a
> third layer (we call them widgets) that you initialize on an action by
> action bases and that this method extends well to allow you to use things
> like Angular or Backbone if that makes you happy.
>
> Best,
> Rob
>
>
> On Feb 16, 2012, at 8:10 , Rafael Cardoso wrote:
>
> > Chris,
> > Here is a gist of how I do it on my app:
> >
> > https://gist.github.com/1846006
> >
> > It works quite well.
> >
> > On Wed, Feb 15, 2012 at 11:23 PM, Guyren Howe <[email protected]> wrote:
> >> On Feb 15, 2012, at 10:32 PM, Chris McCann wrote:
> >>
> >>> I don't quite follow your suggestion regarding adding data-elements --
> >>> can you elaborate?
> >>
> >> HTML5, I think it is, adds the ability to add properties to an HTML
> element with the name data-<name> for any <name>. Such elements are still
> considered correct HTML, and are supported by all major browsers. Before
> HTML5, there wasn’t really any way to do this properly and produce correct
> HTML.
> >>
> >> So you can use this to decorate your elements with whatever information
> your JS code needs to deal with them.
> >>
> >> --
> >> SD Ruby mailing list
> >> [email protected]
> >> http://groups.google.com/group/sdruby
> >
> > --
> > SD Ruby mailing list
> > [email protected]
> > http://groups.google.com/group/sdruby
>
> --
> SD Ruby mailing list
> [email protected]
> http://groups.google.com/group/sdruby

-- 
SD Ruby mailing list
[email protected]
http://groups.google.com/group/sdruby

Reply via email to