Live data from Hacker News

Backbone vs Ember

smus.com

21–30 of 42 posts

Re: Backbone vs Ember

#21
Over the past few weeks I've seen a number of Ember evangelists making claims about BB as 'hard to use' or 'suitable for small apps'.

I don't agree.

The fact is that BB is stable and has loads of documentation and live apps. Ember not so much.

Re: Backbone vs Ember

#22

I'm particularly interested – if anyone has experience using Ember – about the concerns raised about Ember's performance with large amounts of data and "hairy custom view situations," as borismus puts it. Is Ember actually going to be slow when dealing with large data sets?

There are some pretty legitimate concerns with Ember and large data sets right now as the treatment of those datasets tends to be fairly naive and linear. There are several people, myself included, who are working on ways to address that problem--but modifying a large collection, at the moment, can trigger the entire collection to re-render which can be extremely expensive. FWIW, I'm not an expert on Ember.js or Back…

>modifying a large collection, at the moment, can trigger the entire collection to re-render which can be extremely expensive.

How large is large enough to cause problems?

Re: Backbone vs Ember

#23

Guh. A fun dive into politics, but I'm not such a big fan of Boris' conclusions, as you might imagine. > Backbone by itself is not sufficient for building complex web apps. That bit is particularly galling ... It's one thing to opine about stated philosophy, and another thing to really look at how the rubber hits the road. SproutCore/Ember (5 years worth of apps, major corporate backing): http://sproutcore.com/#appli…

Correct me if I'm wrong, but... Backbone is great, but it's also just 600 lines of code aimed at addressing the things every single web app needs, right?

A complex web app, pretty much by definition is going to need some features that other web apps aren't going to need, not so? And those features are, according to the stated goals of Backbone, not going to be found in the core, right? (In fact, I seem to recall people asking for features their particular complex web app needed, and being told that stuff didn't belong in Backbone core...)

Boris' seems to be re-stating Backbones' mission statement, which I don't see being a knock on Backbone at all. And I'm really not sure what a list of people using Backbone is meant to prove. Boris is saying that any of those people using Backbone for complex apps will have to extend it a bit - which is one reason Backbone is made to be so easily extendable. Is that wrong?

Re: Backbone vs Ember

#24
post #16

Boris, I dont know if it happens only to me, but your blog is badly rendered on my Chromium (Linux Mint): many many words are overlapped (like all the paragraph "I like..." under your photo). Everything seems fine in Firefox, I'll try with Chrome on Windows at work. Edit: Chrome on Windows is ok, maybe there's something wrong on my Linux installation

I have the same problem with Chrome on Ubuntu from time to time. Reloading the page usually fixes it. It's annoying, though.

Re: Backbone vs Ember

#25
I see the difference as something like Django/Sinatra vs Rails. Backbone requires the developer to be more explicit, whereas Ember is more opinionated and performs magic behind the scenes as long as you follow the conventions.

On a practical note, my experience earlier this week suggests Backbone right now is far easier to get your hands dirty with. I was excited to use Ember, but I had a practical time constraint and discovered it's a rough ride right now, so reverted to Backbone for this task. There's really very few examples, unless you want to start diving into older Sproutcore docs and trying to figure out the diffs.

In contrast, Backbone has a wealth of articles and even design patterns and books. Of course, it's an apples-versus-oranges distinction with Ember being so much newer, but an important practical issue for developers to be aware of if they're deciding right now.

Re: Backbone vs Ember

#26

We're using both Ember and Backbone here at Square. Backbone has proven useful for small apps ( https://squareup.com/retail ) while Ember is an effective replacement for Rails when it's backed by a good JSON api.

What do you build your JSON api with? I've been using rails against large javascript applications. It seems like ember.js is a good match against rails (especially with https://github.com/emberjs/data)

Re: Backbone vs Ember

#27
post #22

Earlier quoted context omitted.

There are some pretty legitimate concerns with Ember and large data sets right now as the treatment of those datasets tends to be fairly naive and linear. There are several people, myself included, who are working on ways to address that problem--but modifying a large collection, at the moment, can trigger the entire collection to re-render which can be extremely expensive. FWIW, I'm not an expert on Ember.js or Back…

>modifying a large collection, at the moment, can trigger the entire collection to re-render which can be extremely expensive. How large is large enough to cause problems?

I would also like to know this. :-)

Re: Backbone vs Ember

#28
post #27
post #22

Earlier quoted context omitted.

>modifying a large collection, at the moment, can trigger the entire collection to re-render which can be extremely expensive. How large is large enough to cause problems?

I would also like to know this. :-)

me as well.

Re: Backbone vs Ember

#29

Guh. A fun dive into politics, but I'm not such a big fan of Boris' conclusions, as you might imagine. > Backbone by itself is not sufficient for building complex web apps. That bit is particularly galling ... It's one thing to opine about stated philosophy, and another thing to really look at how the rubber hits the road. SproutCore/Ember (5 years worth of apps, major corporate backing): http://sproutcore.com/#appli…

  > Backbone by itself is not sufficient for building complex web apps. 
What he meant was that for any complex web apps built on backbone.js, you have to build a layer on top of it or use additional plugins. You won't build complex applications as is.

IMHO, I consider backbone.js more as a base framework which you need to enhance before starting your project. So, in a way, every complex backbone.js app is more of a extending Backbone.js.

A proof of that is mostly the number of available plugins (which is great!!). As a matter of fact, ender could be written on top of backbone.

Re: Backbone vs Ember

#30
I've been working with Backbone exclusively for the last six months or so, so don't know what other frameworks are doing with nested views. The OP marks this as one of Backbone's shortcomings.

I've been writing my backbone app effectively with nested views, where parent views pass relevant information to child views either through initialization or functions on the child view, while the child view "communicates" with the parent view through events that the PV can bind to.

I kind of like the idea of child views not knowing or caring who created them or why. I do this e.g. with buttons, forms, panels and subpanels, etc.

Is there a good resource for best practices here?

Post reply on HN