首页 产品 设计 查看内容

推荐前端开发脚本框架(javascript)框架

2014-2-28 16:08| 发布者: tianzc| 查看: 4536| 评论: 0

摘要: 来自爱评测整理的前端框架列表脚本框架(具体内容请百度自行学习) jQuery underscore momentjs arale(淘宝) SeaJS Backbone AngularJS ember.js Knockout.js Google Closure Batman.js来自国外的一篇文章的推荐! ...

来自爱评测整理的前端框架列表


web前端脚本框架(具体内容请百度自行学习)

  jQuery

  underscore

  momentjs

  arale(淘宝)

  SeaJS

  Backbone

  AngularJS

  ember.js

  Knockout.js

  Google Closure

  Batman.js


手机web端脚本框架
 
           iUI
         phonegap
jquerymobile
 Sencha Touch
 jqTouch

智能手机现在是越来越被大众接受,即使是诺基亚那可怜的S40,也能将就着算是智能机吧。关键这些智能机里都有一些浏览器了。比如opera mini,opera mobile之类的,再象android那样的话就是Webkit,IOS也算是Webkit核心了(ff也要登录android之类的),opera也在各个平台都有着自己的版本。因此,我们可以假设,只要是智能手机,都能支持一些简单的JS了。但是我怎么知道哪些浏览器支持的JS在其他浏览器上不支持呢?如果只用最简化的功能,那意义就不大了。因此,支持智能手机的JS框架就比较让人心动了。

一、jQuery Mobile

jQueryMobile不像前面SproutCore 或者Sencha Touch,它没有提供一个完整的应用架构。但它是一个新的开始,其也以向移动网站应用提供更多本地化的控制为宗旨。jQuery Mobile项目宣布其要成为“完整的,统一的,移动UI架构”。 jQuery Mobile核心项目也将继续为移动提供优化,但jQuery Mobile更专注于为主流智能手机浏览器提供一种真正的顶级的JS体验和界面。

官方网址:http://jquerymobile.com/

支持列表:http://jquerymobile.com/gbs/

二、Sencha Touch

Sencha前身是Ext JS ,全名是Sencha Touch HTML5 mobile framework.它提供一种可跨平台的架构,目前支持IOS,Android将在不久后得到支持。这种在线摸触摸技术结合了一个UI库的独立解决方 案,触摸项目管理、地理技术支持、离线缓存技术以及特殊的CSS和CSS3功能。

官方网址:http://www.sencha.com/products/touch/

演示地址:http://www.sencha.com/products/touch/demos.php

三、YUI 3.2

雅虎将发布最新的JS实用程序的YUI库。YUI最新版对触摸和移动设备提供更多更好的支持

官方网址:http://yuilibrary.com/

四、iUI

iUI是一个iPhone用户界面架构,其设计目标是像移动网站应用提供更接近iPhone的体验。它的工作原理是结合WEBKIT为基础的设备以及包括一个JS库和CSS及图形。其最早追溯至2007年,但多年以来缓慢地升级以提供更多其他设备,甚至是iPad。

官方网址:http://code.google.com/p/iui/

五、SproutCore

SproutCore是一个HTML5的架构,目标帮助开发者建立桌面口径的web应用,并且支持任何浏览器下无需补丁的运行。其项目带头大哥已经辞去了其原本苹果的职位,专心致志地来完成此项目。

官方网址:http://www.sproutcore.com/

演示地址:http://demo.sproutcore.com/

六、XUI

在开发Phonegap时,XUI团队对应用于移动设备的现存JS库及表现很失望。XUI创建的初衷是跨多个移动浏览器工作,其包括WEBKIT,Fennec,Opera。其目标是为低成本条件下解决传统JS库不适合移动浏览器,提供更多跨兼容的方案。

官方网址:http://xuijs.com/

原文地址:http://www.neatstudio.com/show-1452-1.shtml

来自国外的一篇文章的推荐!

The Contenders

Here is a table showing all of the frameworks support for the above features. Click through the title for more detail.

FrameworkUI BindingsComposed ViewsWeb Presentation LayerPlays Nicely With Others
Backbone.js
SproutCore 1.x
Sammy.js
Spine.js
Cappuccino
Knockout.js
Javascript MVC
Google Web Toolkit
Google Closure
Ember.js
Angular.js
Batman.js

1. Backbone.js

Backbone.js is the web's darling framework. You can't go anywhere without hearing about it and they have an impressive list of brands using it. This was naturally one of the first frameworks I tried. I used it to build some of our internal administrative features atGroupTalent.

Pros: Strong community and lots of momentum. Underscore.js (which it uses heavily) is also a great framework.

Cons: Lacks strong abstractions and leaves something to be desired. The entire framework is surprisingly lightweight and results in lots of boilerplate. The larger an application becomes, the more this becomes apparent.

2. SproutCore 1.x

SproutCore is what Apple used on its iCloud initiative. Despite having a horrible name, it is actually an extremely well thought out framework. It is also one of the largest frameworks.

Pros: Bindings support. Solid community. Tons of features.

Cons: Overly prescriptive. Hard to decouple from unneeded features. Forces a native-like paradigm. I have a serious problem with any framework which discourages using html for layout.

3. Sammy.js

Sammy.js was a smaller framework that I stumbled upon. Due to its simplicity, it almost didn't make this list. It's core feature is a routing system to swap out areas of an application with AJAX.

Pros: Simple learning curve. Easier to integrate with an existing server side app.

Cons: Too simple. Not sufficient for larger applications.

4. Spine.js

Based on the name, Spine.js is obviously heavily influenced by backbone. Like backbone, it is very lightweight and follows a similar model.

Pros: Lightweight with good documentation.

Cons: Fundamentally flawed. A core concept of spine is "is asynchronous UIs. In a nutshell, this means that UIs should ideally never block". Having built a serious non-blocking realtime application in the past, I can say this is entirely unrealistic unless the backend has something like operational transformation.

5. Cappuccino

Cappuccino is one of the more unique frameworks, coming with its own language Objective-J. Cappuccino tries to emulate Cocoa in the browser.

Pros: Large thought-out framework. Good community. Great inheritance model.

Cons: Out of all the languages you could emulate in javascript, Objective-C would be my last choice. This is coming from an iOS developer. I simply can't get past the idea of programming Objective-J in the browser.

6. Knockout.js

Knockout.js is an MVVM framework that receives lots of praise from its supporters. It stresses declarative UI bindings and automatic UI refresh.

Pros: Binding support. Great documentation and amazing tutorial system.

Cons: Awkward binding syntax and lacks a solid view component hierarchy. I want to be able to reuse components easily. I also feel like identifying as an MVVM framework is deleterious. Hardly any of these frameworks are MVC, but are of the MV* variety (MVP, MVVM, etc).

7. Javascript MVC

Javascript MVC, in the interest of full disclosure, is a framework that I didn't spend very much time evaluating.

Pros: Solid community and legacy.

Cons: Awkward inheritance model based on strings. Controllers are too intimate with views and lack bindings. The name is way too generic - the equivalent would be if RoR was called "Ruby Web Framework".

8. Google Web Toolkit

GWT is a serious client-side toolkit that includes more than just a framework. It compiles Java to Javascript, supporting a subset of the standard java library. Google used it internally for Wave.

Pros: Comprehensive framework with great community. Solid Java-based component inheritance model. Great for behemoth client-side applications.

Cons: Despite what Google says, GWT is not going to stand the test of time. With initiatives like DART its clear that Java is not the future of the web. Furthermore, the abstraction of Java on the client is slightly awkward.

9. Google Closure

Google Closure is more of a toolkit than simply a javascript framework. It comes bundled with a compiler and optimizer.

Pros: Use by Google for many of their major apps. Nice component-based ui composition system.

Cons: Lack of UI-binding support.

10. Ember.js

Ember.js (formerly Amber.js SproutCore 2.0) is one of the newest contenders. It is an attempt to extricate the core features from SproutCore 2.0 into a more compact modular framework suited for the web.

Pros: Extremely rich templating system with composed views and UI bindings.

Cons: Relatively new. Documentation leaves lots to be desired.

11. Angular.js

Angular.js is a very nice framework I discovered after I originally posted this review. Developed by Googler's, it has some very interesting design choices.

Pros: Very well thought out with respect to template scoping and controller design. Has a dependency injection system (I am a big fan of IOC). Supports a rich UI-Binding syntax to make things like filtering and transforming values a breeze.

Cons: Codebase appears to be fairly sprawling and not very modular. Views are not modular enough (will address this in more detail in the cons of Batman.js).

12. Batman.js

Batman.js, created by Shopify, is another framework in a similar vein to Knockout and Angular. Has a nice UI binding system based on html attributes. The only framework written in idiomatic coffeescript, it is also tightly integrated with Node.js and even goes to the extent of having its own (optional) Node.js server.

Pros: Very clean codebase. Has a nice simple approach to binding, persistence, and routing.

Cons: I very much dislike singletons, let alone the idea of enforcing singleton controllers. Suffers from the same ailments as Knockout and Angular with regards to nested components. I want to be able to declaratively reuse more than just templates. What Ember has over these frameworks is a way to declaratively re-use entire components that are backed by their own (possibly controller-level) logic.

The Winner

At the end of the day, Ember.js is the only framework which has everything I desire. I recently ported a relatively small Backbone.js application over to Ember.js and, despite some small performance issues, I am much happier with the resulting code base. Being championed by Yehuda Katz, the community around Ember.js is also amazing. This is definitely the framework to watch out for.

Of course this list is far from comprehensive. Almost all of these frameworks here were discovered by sheer notoriety, word of mouth, or by being mentioned on Hacker News. I am also not reviewing proprietary frameworks (or frameworks with disagreeable licenses - ExtJS anyone?).

What MVC framework do you use?


鲜花

握手

雷人

路过

鸡蛋
公告

    扫一扫关注最新动态

    毒镜头:老镜头、摄影器材资料库、老镜头样片、摄影
    爱评测 aipingce.com  
    返回顶部