I want to start the discussion about removing TemplateView/Handlebars
from the SproutCore Codebase. It would not go away entirely, just be
a opt-in view rendering framework built on top of SC.View. This means
that people don't need to use it if they don't want to.
Pros:
- Reduce Code Size
- Don't force the TemplateView paradigm
Cons:
- Abstracts the TemplateView from the View Layer
Post Comments...
Kyle Carriedo
Chad Eubanks
Sent from my iPhone
On Dec 12, 12:35 pm, Maurits Lamers <mauritslam...@gmail.com> wrote:
> Seems to be a good idea, though there is one problem: in order to make templates work, there have been some changes to the bindings.
> Should these also be pulled out? If yes, how will the template layer be made to work?
>
> Op 12 dec 2011, om 18:29 heeft Kyle Carriedo het volgende geschreven:
>
>
>
>
>
>
>
> > +1 I agree
>
> > Kyle Carriedo
>
Topher:
You can get that same functionality with the normal view system, by
implementing SC.CollectionRowDelegate...I think the API needs to be
improved a little...like adding a property-like
'hasContentDefinedRowHeight' to trigger fully custom row height calls.
Evin
On Dec 12, 1:35 pm, Tyler Keating <ty...@sproutcore.com> wrote:
> +1. I would like it if each view system was modularized properly so that we could work with one, both or neither. This would make it easier to introduce an entirely new optional view system, like the Canvas based one that Erich has proposed, without forcing anyone to abandon the current systems. Since SC.View and SC.TemplateView are both extensions of SC.CoreView, I think we're already on the right path and it seems like modularizing SC.TemplateView first is the best step.
>
> Anecdotally, I'm bringing TemplateViews higher up the view chain more and more each day. So I would be one of the people interested in supporting that sub-framework/sub-project.
>
> For reference, there's a similar discussion here:https://github.com/sproutcore/sproutcore/issues/635
>
> --
> Tyler Keating
>
>
>
>
>
>
>
> On Monday, December 12, 2011 at 12:01 PM, Juan Camilo Pinzón wrote:
> > Agree with Maurits. I have no problem moving it out (not removing it), but I think is not as simple as moving files. It would need somebody with enough knowledge and plenty of baking time.
>
> > TemplateViews fill a gap that SC always had and it does a great job at it. As Topher mentioned is a great solution when stuff like collection view doesn't fit the requirements or it's too heavy.
>
> > You just have to be smart about when to use traditional SC.Views or Template views.
>
> > On Dec 12, 2011, at 9:41 AM, Topher Fangio wrote:
> > > I am in favor of removing/moving the TemplateView to simplify/standardize, however, one of the main reasons that I used it was so that I could more easily render list views with unknown heights. I would love to replace my current TemplateViews with another solution, but I couldn't find one that worked very well.
>
> > > So, I would say this: if we remove/move TemplateView, it would be good to have a clear and documented way that Sproutcore can accomplish similar things with the existing code. Since I doubt it was used heavily, I doubt that we need a full "Porting from 1.6 to 1.7" guide or something like that, but some documentation would be good. If I had help with the solution, I would certainly be willing to write the guide showing others how to do it.
>
> > > --Topher Fangio
>
> > > System Architect
> > > Pharos Resources
>
> > > office: 325.216.2908
> > > mobile: 325.660.7141
>
> > > On Mon, Dec 12, 2011 at 11:35 AM, Maurits Lamers <mauritslam...@gmail.com (mailto:mauritslam...@gmail.com)> wrote:
> > > > Seems to be a good idea, though there is one problem: in order to make templates work, there have been some changes to the bindings.
> > > > Should these also be pulled out? If yes, how will the template layer be made to work?
>
> > > > Op 12 dec 2011, om 18:29 heeft Kyle Carriedo het volgende geschreven:
>
> > > > > +1 I agree
>
> > > > > Kyle Carriedo
>