SlideShare une entreprise Scribd logo
1  sur  15
Télécharger pour lire hors ligne
AngularJS – An Introduction


Nitya Narasimhan
@nitya


NYC GTUG Meetup
February 27, 2013
About Me

¤  15+ years R&D, past 10 years in industry

¤  Survivable Distributed Java Systems (PhD)

¤  Early Stage Technology Development (Motorola)

¤  Education Technology, Learning Analytics (Independent)

¤  Interests: mobile computing, social software, interactive
    television, sentient computing, adaptive learning

¤  Relative novice to front-end web development
Web App Design Challenge
                                          One app per
                             MY UI          platform
                                       (local optimization)




                                                                 MY
                                                                 DB




                                               NETWORK
                                               LATENCY        MY SERVER
                             MY UI

                                             Round-trip per
                                              page load
                                                                          THIRD PARTY
DEVICE DIVERSITY     BROWSER DIVERSITY                                     SERVICES
Responsive Design   Cross-platform testing
What I was looking for …

¤  Enable Responsive Design (across device form factors)

¤  Single Page App Support (deep linking, dynamic views)

¤  Long term relevance (active community, adoption)

¤  Ease of development (bootstrapping, docs, examples)

¤  Ease of testing (built-in test harness, testing tools)

¤  Flexibility in usage (extensible, embeddable)
AngularJS looked promising ..
                                                    V1.1.1




                                           V1.0.3




                       V1.0.0




http://trends.builtwith.com/javascript/Angular-JS            http://builtwithangularjs.org
What is AngularJS?

¤  “HTML enhanced for web apps”

¤  Open-sourced by Google (2009)

¤  MVC JavaScript framework

¤  Programming philosophy:
  ¤  View = Declarative
  ¤  Controller = Imperative
  ¤  Clean separation, reduced
      complexity (no ugly DOM wrangling)
Hello World! (angularjs.org)




                                      Directives are
                                      totally cool!!

•  Maintains familiar HTML syntax
•  Masks DOM manipulation from UI developer
Under the (browser) hood..
•    Angular enhances HTML
     vocabulary (directives)

•    Browser loads static HTML,
     parses DOM

•    Angular identifies app
     boundary (ng-app), locates
     related module

•    Angular module, compiles
     directive (injects dependency,
     adds $scope context)

•    Browser renders HTML (view)


                                      Developer Guide >> Conceptual Overview
Critical Concept = $scope
•  Object representing
   application model

•  “Root” scope, hierarchy of
   “child” scopes (DOM-like)

•  Detect changes to model,
   Creates execution context
   for expressions

•  Can watch expressions,
   propagate changes to views

•  Decouples view & controller
                                 Developer Guide >> Conceptual Overview
Key Concepts
¤  Model = plain JavaScript object (no inheritance)

¤  View = declarative (in HTML), based on DOM objects

¤  Controller = imperative (logic), constructs “Model”,
    connects it to “View” via the $scope intermediary.

¤  Services = “common” tasks, data-sharing for controllers

¤  Filters = data transformation, can be chained together

¤  Directive = transform DOM, ‘declare’ new behaviors

¤  Module = declarative configuration (for app startup)
M-V-C in action (angularjs.org)
               View = HTML




              Directives
              (augment DOM)

                                    Controller = JS


                 Expressions
                 (filter chains)




                    Model = Scope
Key Features

¤  Custom directives (enhance HTML your way)

¤  2-way data binding (effortless sync of modelóview)

¤  Deep linking (single-page, normal navigation)

¤  Form validation (at client, with declarative rules)

¤  Dependency injection (with declarative wiring)

¤  Born testable, very embeddable (plays nice w/ others)
Quick Start (Yeoman workflow)




     Test
     Harness
Resources

¤  AngularJS Developer Guide

¤  PhoneCat Tutorial (example)

¤  Egghead.io (28 videos)

¤  AngularJS Starter (66 pages, code)

¤  AngularJS Generator (http://yeoman.io)

¤  BuiltWithAngularJS.org (Examples)
Interest in Deep Dives??

¤  Directives, Expressions, Filters

¤  Scope API ($watch, $apply)

¤  Deep Linking (Routing & Navigation)

¤  Modules, Services & Controllers

¤  Dependency Injection

¤  Workflow Automation & E2E Testing

Contenu connexe

Tendances

Browser and Cloud - The Future of IDEs?
Browser and Cloud - The Future of IDEs?Browser and Cloud - The Future of IDEs?
Browser and Cloud - The Future of IDEs?
martinlippert
 

Tendances (13)

AngularJS NYC Meetup: UX Prototyping and Business Development with AngularJS
AngularJS NYC Meetup: UX Prototyping and Business Development with AngularJSAngularJS NYC Meetup: UX Prototyping and Business Development with AngularJS
AngularJS NYC Meetup: UX Prototyping and Business Development with AngularJS
 
Swing !!! y shikhar!!
Swing !!! y shikhar!!Swing !!! y shikhar!!
Swing !!! y shikhar!!
 
Test
TestTest
Test
 
Sai Sharan_UI_Resume
Sai Sharan_UI_ResumeSai Sharan_UI_Resume
Sai Sharan_UI_Resume
 
新版阿尔法城背后的前端MVC实践
新版阿尔法城背后的前端MVC实践新版阿尔法城背后的前端MVC实践
新版阿尔法城背后的前端MVC实践
 
Module System of JavaScript
Module System of JavaScriptModule System of JavaScript
Module System of JavaScript
 
Introduction to backbone_js
Introduction to backbone_jsIntroduction to backbone_js
Introduction to backbone_js
 
Going offline with JS (DDD Sydney)
Going offline with JS (DDD Sydney)Going offline with JS (DDD Sydney)
Going offline with JS (DDD Sydney)
 
Angular js
Angular jsAngular js
Angular js
 
Use Your WebDev Skills to Create Mobile Apps in Telerik Appbuilder (Jonathan ...
Use Your WebDev Skills to Create Mobile Apps in Telerik Appbuilder (Jonathan ...Use Your WebDev Skills to Create Mobile Apps in Telerik Appbuilder (Jonathan ...
Use Your WebDev Skills to Create Mobile Apps in Telerik Appbuilder (Jonathan ...
 
Learn skills technologies
Learn skills technologiesLearn skills technologies
Learn skills technologies
 
Browser and Cloud - The Future of IDEs?
Browser and Cloud - The Future of IDEs?Browser and Cloud - The Future of IDEs?
Browser and Cloud - The Future of IDEs?
 
Kendo UI presentation at JsConf.eu
Kendo UI presentation at JsConf.euKendo UI presentation at JsConf.eu
Kendo UI presentation at JsConf.eu
 

En vedette

En vedette (20)

Battle of Frameworks: Polymer - Meetup Paris Web Components - 2016-09
Battle of Frameworks: Polymer - Meetup Paris Web Components - 2016-09Battle of Frameworks: Polymer - Meetup Paris Web Components - 2016-09
Battle of Frameworks: Polymer - Meetup Paris Web Components - 2016-09
 
Apresentação Google I/O Extended Vitória
Apresentação Google I/O Extended VitóriaApresentação Google I/O Extended Vitória
Apresentação Google I/O Extended Vitória
 
Material design
Material designMaterial design
Material design
 
Um salve para evolução! construindo uma nova web com polymer
Um salve para evolução! construindo uma nova web com  polymerUm salve para evolução! construindo uma nova web com  polymer
Um salve para evolução! construindo uma nova web com polymer
 
The Beautiful Simplicity of ES2015
The Beautiful Simplicity of ES2015The Beautiful Simplicity of ES2015
The Beautiful Simplicity of ES2015
 
Polymer Elements: Tudo que você precisa saber para criar a web
Polymer Elements: Tudo que você precisa saber para criar a webPolymer Elements: Tudo que você precisa saber para criar a web
Polymer Elements: Tudo que você precisa saber para criar a web
 
O futuro do Android
O futuro do AndroidO futuro do Android
O futuro do Android
 
Chrome Dev Summit Highlights (NYC GDG Dec 2013)
Chrome Dev Summit Highlights (NYC GDG Dec 2013)Chrome Dev Summit Highlights (NYC GDG Dec 2013)
Chrome Dev Summit Highlights (NYC GDG Dec 2013)
 
WebApps com Web Components
WebApps com Web ComponentsWebApps com Web Components
WebApps com Web Components
 
Polymer and Firebase: Componentizing the Web in Realtime
Polymer and Firebase: Componentizing the Web in RealtimePolymer and Firebase: Componentizing the Web in Realtime
Polymer and Firebase: Componentizing the Web in Realtime
 
Introduction To Dart (GDG NY Jan 2014 Meetup)
Introduction To Dart (GDG NY Jan 2014 Meetup)Introduction To Dart (GDG NY Jan 2014 Meetup)
Introduction To Dart (GDG NY Jan 2014 Meetup)
 
Polymer Starter Kit
Polymer Starter KitPolymer Starter Kit
Polymer Starter Kit
 
Material Design - do smartphone ao desktop
Material Design - do smartphone ao desktopMaterial Design - do smartphone ao desktop
Material Design - do smartphone ao desktop
 
Workshop de Web Components
Workshop de Web ComponentsWorkshop de Web Components
Workshop de Web Components
 
Web components
Web componentsWeb components
Web components
 
Tech talk polymer
Tech talk polymerTech talk polymer
Tech talk polymer
 
Angular 2 overview workshop
Angular 2 overview workshopAngular 2 overview workshop
Angular 2 overview workshop
 
Pensando em UX / UI com o material design
Pensando em UX / UI com o material designPensando em UX / UI com o material design
Pensando em UX / UI com o material design
 
Angular 2 - a New Hope
Angular 2 - a New HopeAngular 2 - a New Hope
Angular 2 - a New Hope
 
Web components + Material design = Polymer (by Vyatcheslav Potravnyy) - Hack'...
Web components + Material design = Polymer (by Vyatcheslav Potravnyy) - Hack'...Web components + Material design = Polymer (by Vyatcheslav Potravnyy) - Hack'...
Web components + Material design = Polymer (by Vyatcheslav Potravnyy) - Hack'...
 

Similaire à Angular js gtg-27feb2013

Wintellect - Devscovery - Enterprise JavaScript Development 2 of 2
Wintellect - Devscovery - Enterprise JavaScript Development 2 of 2Wintellect - Devscovery - Enterprise JavaScript Development 2 of 2
Wintellect - Devscovery - Enterprise JavaScript Development 2 of 2
Jeremy Likness
 
AngularJS UTOSC
AngularJS UTOSCAngularJS UTOSC
AngularJS UTOSC
roboncode
 

Similaire à Angular js gtg-27feb2013 (20)

Angular JS, A dive to concepts
Angular JS, A dive to conceptsAngular JS, A dive to concepts
Angular JS, A dive to concepts
 
Angular JS - Introduction
Angular JS - IntroductionAngular JS - Introduction
Angular JS - Introduction
 
Tasvir_UI Developer
Tasvir_UI DeveloperTasvir_UI Developer
Tasvir_UI Developer
 
Comparative analysis of java script framework
Comparative analysis of java script frameworkComparative analysis of java script framework
Comparative analysis of java script framework
 
Javascript frameworks
Javascript frameworksJavascript frameworks
Javascript frameworks
 
AngularJS Anatomy & Directives
AngularJS Anatomy & DirectivesAngularJS Anatomy & Directives
AngularJS Anatomy & Directives
 
Neha Bhandari CV
Neha Bhandari CVNeha Bhandari CV
Neha Bhandari CV
 
The future of web development write once, run everywhere with angular js an...
The future of web development   write once, run everywhere with angular js an...The future of web development   write once, run everywhere with angular js an...
The future of web development write once, run everywhere with angular js an...
 
The future of web development write once, run everywhere with angular.js and ...
The future of web development write once, run everywhere with angular.js and ...The future of web development write once, run everywhere with angular.js and ...
The future of web development write once, run everywhere with angular.js and ...
 
Angular from Zero to Mastery - Training (Intermediate)
Angular from Zero to Mastery - Training (Intermediate)Angular from Zero to Mastery - Training (Intermediate)
Angular from Zero to Mastery - Training (Intermediate)
 
Wintellect - Devscovery - Enterprise JavaScript Development 2 of 2
Wintellect - Devscovery - Enterprise JavaScript Development 2 of 2Wintellect - Devscovery - Enterprise JavaScript Development 2 of 2
Wintellect - Devscovery - Enterprise JavaScript Development 2 of 2
 
Angular JS - UI Development Online Training
Angular JS - UI Development Online TrainingAngular JS - UI Development Online Training
Angular JS - UI Development Online Training
 
Resume_Venugopal
Resume_VenugopalResume_Venugopal
Resume_Venugopal
 
AngularJS UTOSC
AngularJS UTOSCAngularJS UTOSC
AngularJS UTOSC
 
Niraj Choudhary_Resume
Niraj Choudhary_ResumeNiraj Choudhary_Resume
Niraj Choudhary_Resume
 
AngularJS - Architecture decisions in a large project 
AngularJS - Architecture decisionsin a large project AngularJS - Architecture decisionsin a large project 
AngularJS - Architecture decisions in a large project 
 
Responsive web design with Angularjs
Responsive web design with AngularjsResponsive web design with Angularjs
Responsive web design with Angularjs
 
Single Page Applications - Desert Code Camp 2012
Single Page Applications - Desert Code Camp 2012Single Page Applications - Desert Code Camp 2012
Single Page Applications - Desert Code Camp 2012
 
Angular js workshop
Angular js workshopAngular js workshop
Angular js workshop
 
Mahesh_Dimble
Mahesh_DimbleMahesh_Dimble
Mahesh_Dimble
 

Dernier

Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Victor Rentea
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Dernier (20)

Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 

Angular js gtg-27feb2013

  • 1. AngularJS – An Introduction Nitya Narasimhan @nitya NYC GTUG Meetup February 27, 2013
  • 2. About Me ¤  15+ years R&D, past 10 years in industry ¤  Survivable Distributed Java Systems (PhD) ¤  Early Stage Technology Development (Motorola) ¤  Education Technology, Learning Analytics (Independent) ¤  Interests: mobile computing, social software, interactive television, sentient computing, adaptive learning ¤  Relative novice to front-end web development
  • 3. Web App Design Challenge One app per MY UI platform (local optimization) MY DB NETWORK LATENCY MY SERVER MY UI Round-trip per page load THIRD PARTY DEVICE DIVERSITY BROWSER DIVERSITY SERVICES Responsive Design Cross-platform testing
  • 4. What I was looking for … ¤  Enable Responsive Design (across device form factors) ¤  Single Page App Support (deep linking, dynamic views) ¤  Long term relevance (active community, adoption) ¤  Ease of development (bootstrapping, docs, examples) ¤  Ease of testing (built-in test harness, testing tools) ¤  Flexibility in usage (extensible, embeddable)
  • 5. AngularJS looked promising .. V1.1.1 V1.0.3 V1.0.0 http://trends.builtwith.com/javascript/Angular-JS http://builtwithangularjs.org
  • 6. What is AngularJS? ¤  “HTML enhanced for web apps” ¤  Open-sourced by Google (2009) ¤  MVC JavaScript framework ¤  Programming philosophy: ¤  View = Declarative ¤  Controller = Imperative ¤  Clean separation, reduced complexity (no ugly DOM wrangling)
  • 7. Hello World! (angularjs.org) Directives are totally cool!! •  Maintains familiar HTML syntax •  Masks DOM manipulation from UI developer
  • 8. Under the (browser) hood.. •  Angular enhances HTML vocabulary (directives) •  Browser loads static HTML, parses DOM •  Angular identifies app boundary (ng-app), locates related module •  Angular module, compiles directive (injects dependency, adds $scope context) •  Browser renders HTML (view) Developer Guide >> Conceptual Overview
  • 9. Critical Concept = $scope •  Object representing application model •  “Root” scope, hierarchy of “child” scopes (DOM-like) •  Detect changes to model, Creates execution context for expressions •  Can watch expressions, propagate changes to views •  Decouples view & controller Developer Guide >> Conceptual Overview
  • 10. Key Concepts ¤  Model = plain JavaScript object (no inheritance) ¤  View = declarative (in HTML), based on DOM objects ¤  Controller = imperative (logic), constructs “Model”, connects it to “View” via the $scope intermediary. ¤  Services = “common” tasks, data-sharing for controllers ¤  Filters = data transformation, can be chained together ¤  Directive = transform DOM, ‘declare’ new behaviors ¤  Module = declarative configuration (for app startup)
  • 11. M-V-C in action (angularjs.org) View = HTML Directives (augment DOM) Controller = JS Expressions (filter chains) Model = Scope
  • 12. Key Features ¤  Custom directives (enhance HTML your way) ¤  2-way data binding (effortless sync of modelóview) ¤  Deep linking (single-page, normal navigation) ¤  Form validation (at client, with declarative rules) ¤  Dependency injection (with declarative wiring) ¤  Born testable, very embeddable (plays nice w/ others)
  • 13. Quick Start (Yeoman workflow) Test Harness
  • 14. Resources ¤  AngularJS Developer Guide ¤  PhoneCat Tutorial (example) ¤  Egghead.io (28 videos) ¤  AngularJS Starter (66 pages, code) ¤  AngularJS Generator (http://yeoman.io) ¤  BuiltWithAngularJS.org (Examples)
  • 15. Interest in Deep Dives?? ¤  Directives, Expressions, Filters ¤  Scope API ($watch, $apply) ¤  Deep Linking (Routing & Navigation) ¤  Modules, Services & Controllers ¤  Dependency Injection ¤  Workflow Automation & E2E Testing