Angular各個(gè)版本之間到底有什么區(qū)別

AngularJS是Angular 1,? https://angular.io/guide/ajs-quick-reference 有更詳細(xì)的信息;

MVVM(Model-View-ViewModel)組件相關(guān);component based and allows rapid creation of UI features.

React can be used as a UI library to render elements

React Elements?are the smallest building blocks of React apps.?Components?are larger building blocks that define independent and reusable pieces to be used throughout the application.?JSX?(JavaScript XML)


在react推出next之后,vue也推出了nuxt, nuxt是nodejs+vue.js有利于SEO,UI渲染不同于模板引擎渲染

The Vue.js core library focuses on the View layer only.?

Components?in Vue are small, self-contained, and can be reused throughout the application.?Single File Components?(SFCs) with the?.vue?extension contain HTML, CSS, and JavaScript so that all relevant code resides in one file.


Angular: 模塊、組件和服務(wù);如果僅僅用於PC 端的WEB開發(fā), Angular 1.x足以應(yīng)對; 如果是用於 mobile app ,在用戶體驗(yàn)方面,略顯捉襟見肘;Angular 1 代碼是基於 JavaScript 寫的;在 Angular 1 中,最為常用的是 $scope 在 Angular 2和4中被去掉了。在新版本中,更多推崇的是 directive 和 controller, 通過對 component 組件的split(分割),從而實(shí)現(xiàn)代碼的復(fù)用,directive就是ng-開頭的,controller就是三套架構(gòu)里的其中之一;

Projects in Angular are structured into?Modules,?Components, and?Services.Angular is built in TypeScript.

Aside from components, Angular supports modules and services.

Start coding new UI features with Angular

Template basics, bindings,filter or pipe "|", *ngFor, let

Template directives

https://angular.io/guide/ajs-quick-reference

ng-controller to @Component, ng-model, ng-repeat, ng-modules

controller function turn to component class


Modules/controllers/components

In AngularJS, you write the code that provides the model and the methods for the view in acontroller.In Angular, you build acomponent.


Inject dependencies

https://angular.io/guide/ajs-quick-reference




ready-to-use components?

Angular is part of the well-known MEAN stack that combines Angular with MongoDB, ExpressJS, and NodeJS. Similar to the MERN() stack, it relies entirely on JavaScript for both the front-end and back-end.

Angular, React, and Vue can all be used to develop Progressive Web Apps, also known as PWAs.

?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

推薦閱讀更多精彩內(nèi)容