Javascript Meteor、Ember.js 和 Backbone.js 之间的主要区别是什么?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/10099059/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-23 23:50:29  来源:igfitidea点击:

What are the key differences between Meteor, Ember.js and Backbone.js?

javascriptbackbone.jsknockout.jsember.jsmeteor

提问by K Z

Learning Ember.js / Backbone.js has been on my to-do list for a while. Now that Meteoris out, I am just wondering if anyone with experience of Meteor, Ember.js and Backbone.js can summarize the key differences and pros and cons of these three JavaScript frameworks for a person without any experience for any of them.

学习 Ember.js / Backbone.js 已经在我的待办事项清单上有一段时间了。现在Meteor出来了,我只是想知道是否有任何人对 Meteor、Ember.js 和 Backbone.js 有经验,可以为一个没有任何经验的人总结这三个 JavaScript 框架的主要区别和优缺点。

Specifically, I would like to know which tasks each framework is more suitable for, and why the others aren't.

具体来说,我想知道每个框架更适合哪些任务,以及为什么其他框架不适合。

Edit: now that I read a little bit more on Meteor, it seems to be more similar to Knockout.js rather than Backbone.js. So any comparison with Knockout.js is welcome too.

编辑:现在我阅读了更多关于 Meteor 的内容,它似乎更类似于 Knockout.js 而不是 Backbone.js。所以任何与 Knockout.js 的比较也是受欢迎的。

采纳答案by joevallender

There is a nice run down/comparison of various MVx JS frameworks here http://codebrief.com/2012/01/the-top-10-javascript-mvc-frameworks-reviewed/it's followed by a good discussion in the comments too. I think I've seen Gordon (who wrote it) on here so maybe you'll get a reply from him.

http://codebrief.com/2012/01/the-top-10-javascript-mvc-frameworks-reviewed/这里有一个很好的运行/比较各种 MVx JS 框架 ,然后在评论中也进行了很好的讨论. 我想我在这里看到了戈登(他写的),所以也许你会得到他的答复。

I'd say if you are looking to learn this style of application development then on the one hand, the wealth of open source backbone examples around could be good for you. But on the other hand, although new, the Ember packageis actually more complete IMO than backbone.

我想说的是,如果您想学习这种应用程序开发风格,那么一方面,丰富的开源主干示例可能对您有好处。但另一方面,虽然是新的,但 Ember实际上比主干更完整的 IMO。

Both give you the ability to implement things in a variety of ways which can be confusing, but Ember provides more of the code that you would have to write yourself in backbone as standard which for me personally is more important for rapid prototyping than the wealth of backbone examples available.

两者都使您能够以各种可能令人困惑的方式实现事物,但是 Ember 提供了更多您必须在主干中作为标准编写的代码,这对我个人而言对于快速原型设计比财富更重要可用的主干示例。

There are more mature plugings for data persistence for backbone, but there is a great community buzz around Ember and lots of contrib libraries are making great progress. I've been pleasantly surprised with how quick I (and others) have had quality responses for a relatively new framework here on Stack Overflow.

有更成熟的数据持久化插件用于主干,但是围绕 Ember 有一个很好的社区嗡嗡声,并且许多 contrib 库正在取得很大进展。我(和其他人)在 Stack Overflow 上对一个相对较新的框架做出了高质量的回应,这让我感到惊喜。

When you say meteor we are talking about totally other stuff. If you wanted to do more with code re-use on both client and server side then take a look the recently open sourced yahoo mojito https://github.com/yahoo/mojitorunning on node.js - I've been messing around with it over the last week, and If you become familiar with backbone/ember or any of the others its a snap to get to grips with.

当你说流星时,我们在谈论完全不同的东西。如果你想在客户端和服务器端做更多的代码重用,那么看看最近开源的 yahoo mojito https://github.com/yahoo/mojito在 node.js 上运行 - 我一直在搞乱在过去的一周里,如果你熟悉了主干/余烬或其他任何一个,它就会很快掌握。

I should also say I have Knockout.js in use on some production systems but have never used it for a fully fledged 'application'. I've got it hooked up to a mongo interface for drilling down into and pageing logs stored in mongo. I really like it, but I wouldn't feel comfortable building anything too big in it.

我还应该说,我在某些生产系统上使用了 Knockout.js,但从未将其用于完全成熟的“应用程序”。我已经将它连接到一个 mongo 界面,用于深入查看和分页存储在 mongo 中的日志。我真的很喜欢它,但我不喜欢在里面建造任何太大的东西。

Well, that's a bit of a ramble - isn't it :)

好吧,这有点啰嗦 - 不是吗:)

Quite happy to talk more about it with anyone who is interested. I've used a number of these frameworks in anger/production (including things not listed in the 'top 10' article) and people at work are sick of hearing me talk about JS i think :-D

很高兴与任何感兴趣的人谈论更多。我在愤怒/生产中使用了许多这样的框架(包括未在“前 10 名”文章中列出的内容),工作人员听我谈论 JS 感到厌烦,我认为 :-D