用于 Javascript 的 Ruby on Rails
我在 Ruby on Rails 方面有一些经验,并且希望在我的客户端 Javascript 项目中保留 MVC 方式。
有没有类似 Rails 的 Javascript 框架?它应该具有以下功能:
- MVC
- 与 REST Web 服务轻松集成
- JavaScript 驱动的模板系统
- 模型和验证
- 测试框架
可靠的文档是必须的!
I have some experience in Ruby on Rails and I want to keep the MVC way to go in my client side Javascript project.
There is any Rails-like framework for Javascript? It should have the following features:
- MVC
- Easy integration with REST web services
- Javascript-driven templating system
- Models and validations
- Testing framework
A solid documentation is a must!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
我今天发现了 backbone.js。值得一看。它似乎是一个轻量级抽象 MVC 系统,并使用 underscore.js 和 jQuery
至于客户端测试,不包括在内。有许多独立的单元测试库。
只需添加您想要的任何客户端测试库即可。有了这 4 个,你真的不需要其他任何东西了。
还有更重量级的替代品,例如 SproutCore 或 卡布奇诺#
另请参阅 知道
我认为 node.js 也值得一提,以防你想委托一些你的工作框架到服务器,但将其保留在 javascript 中。不过,您必须研究一些在节点上运行的大型库。
I discovered backbone.js today. It's worth a look. It appears to be a lightweight abstract MVC system and uses underscore.js and jQuery
As for client side testing this isn't included. There are many standalone unit testing libraries out there.
Just add in any client side testing library you want. With these 4 you really shouldn't need anything else.
There are more heavyweight alternatives like SproutCore or Cappuccino#
Also see a large thread here on the topic by people in the know
I think node.js is worthy a mention aswell in case you want to delegate some of your framework to the server but keep it in javascript. You'll have to look into some of the big libraries running on node though.
尝试 http://emberjs.com/。它是一个非常雄心勃勃的 Javascript 框架,具有 UI 绑定和自动更新模板等很酷的功能。它与 jQuery 配合得很好;)
Try http://emberjs.com/. It's very ambitious Javascript framework with cool things like UI Bindings and Auto-updating templates. It plays well with jQuery ;)
Javascript MVC 功能非常齐全,并且包含许多优秀的测试工具:http://javascriptmvc.com/
查看此答案以获取更多信息:
是否有 JavaScript MVC(微)框架?
Javascript MVC is pretty full-featured and has a lot of good testing tools included: http://javascriptmvc.com/
Check out this answer for more info:
Is there a JavaScript MVC (micro-)framework?