Skip to content

Comment on An Intro to Backbone.js: Part 3 - Binding a Collection to a Viewparent

Comments

I didn't meant to say that Donut was itself a mapping from data to representation, just that there is some kind of mapping somewhere. I absolutely agree that Donut should not be concerned with its representation(s).

In Flex, this is managed by a 2-part view consisting of the collection view (List) and the item view (ItemRenderer). When creating the List you pass it its data provider (oft. ArrayCollection) and its ItemRenderer.

Perhaps this example could benefit from a similar separation.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.