SlideShare a Scribd company logo
Hiten Pratap Singh
http://github.com/hitenpratap
http://hprog99.wordpress.com
AngularJS from novice to
professional
Agenda
1. What is AngularJS?
2. Core features
3. It's working
4. How to start working with it?
5. Controller
6. AngularJS directives
7. Expression
8. Forms
9. Services
Agenda
10. Modules
9. Routing
10. Scope
11. Dependency Injection
12. Filters
13. Advantages and disadvantages
14. References
15. Q/A
16. Quiz
What's AngularJS?
AngularJS (commonly referred to as "Angular") is an
open-source web application framework maintained by
Google to address many of the challenges encountered
in developing single-page applications. It aims to simplify
both the development and the testing of such
applications by providing a framework for client-side
model–view–controller (MVC) – As per Wikipedia.
Core features
1.Two way data binding
2.Templates
3.Model view controller(MVC)
4.Dependency Injection
Two Way Data Binding
Templates
 In AngularJS, a template is just plain-old-HTML. The
HTML vocabulary is extended, to contain instructions
on how the model should be projected into the view.
 The HTML templates are parsed by the browser into
the DOM. The DOM then becomes the input to the
AngularJS compiler. AngularJS traverses the DOM
template for rendering instructions, which are called
directives. Collectively, the directives are responsible
for setting up the data-binding for your application
view.
Model View Controller(MVC or MVVC)
Dependency Injection
AngularJS Working
Hello World - AngularJS
AngularJS Controller
AngularJS Directives
 ng-app: Declares an element as root element
 ng-bind: Automatically changes the text of HTML element
 ng-model: Similar to ng-bind but allow two way binding
 ng-class: Allow class attribute to be dynaically loaded
 ng-controller: Specifies javascript controller class
 ng-repeat: Instantiate an element once per item from a collection
 ng-show & ng-hide: Conditionally show or hide an element
 ng-switch: Conditionally instantiate one template from a list
 ng-view: Rendering templates driven by specific controllers
 ng-if: Simple if-else attribute that we know from ever!
AngularJS Expression
Angular Form Properties $valid, $invalid, $pristine, $dirty
Angular also provides classes on the form and its inputs so that
you can style each state accordingly.
AngularJS Services
In Angular a service is a function or an object and is used to share data
and/or behavior across controllers, directives, filters, other services etc. A
service is treated as a singleton, that is there is only one instance of a
specific service available during the whole lifetime of the Angular
application. This is different from e.g. a controller of which many
instances can be created.
The easiest way is to use the Service recipe of an angular module.
var app = angular.module('app', []);
app.service('some-service', function(){…});
Other two methods/way to create service are:
1. The factory recipe
2.The provider recipe
AngularJS Module
AngularJS Routing
AngularJS Scope
AngularJS Dependency Injection
AngularJS has a built-in dependency injection subsystem that
helps the developer by making the application easier to develop,
understand, and test.
Dependency Injection (DI) allows you to ask for your
dependencies, rather than having to go look for them or make
them yourself. Think of it as a way of saying "Hey I need X', and
the DI is responsible for creating and providing it for you.
To gain access to core AngularJS services, it is simply a matter of
adding that service as a parameter; AngularJS will detect that you
need that service and provide an instance for you.
AngularJS Filters
Angular exposes a simple API for creating a filter. Just as you
would declare a controller with app.controller(‘myCtrl',
function(){});, you can create a new filter by appending
.filter(‘filterName', function(){}) to your Angular app.
AngularJS Advantages
 Super fast development
 Makes developing SPA easy
 Awesome performance
 Make apps scalable
 Data binding and DOM manipulation
AngularJS Disadvantages
 Good for I/O driven apps only(not games)
 Angular is big and complicated. With multiple ways to do
the same thing it is hard to tell which way is better for
particular task.
 The lifecycle of Angular application is complex, and to
master it you really need to read the code.
References
 AngularJS Docs(https://docs.angularjs.org/tutorial)
 AngularJS API Reference(https://docs.angularjs.org/api)
 AngularJS Code School(http://angular.codeschool.com/)
 ng-newsletter(http://www.ng-newsletter.com/books/)
Discussion Session
QUERIES ?
Hiten Pratap Singh
http://github.com/hitenpratap
http://hprog99.wordpress.com
Quiz Time
Anyone have any suggestons about what it should be? If no
then
We'll build an online contact manager just like
Google Contact.

More Related Content

PPTX
Introduction to Angularjs
PPTX
Angularjs PPT
PPTX
Introduction to AngularJS
PPTX
Angular js PPT
PPTX
JavaScript New Tutorial Class XI and XII.pptx
ODP
Datatype in JavaScript
PPTX
Modern JS with ES6
PDF
Javascript essentials
Introduction to Angularjs
Angularjs PPT
Introduction to AngularJS
Angular js PPT
JavaScript New Tutorial Class XI and XII.pptx
Datatype in JavaScript
Modern JS with ES6
Javascript essentials

What's hot (20)

PDF
TypeScript
PPTX
Angular Data Binding
PDF
Angular data binding
PDF
Angular - Chapter 7 - HTTP Services
PPTX
Intro to React
PPTX
Introduction to angular with a simple but complete project
PPTX
Express js
PPTX
Modules in AngularJs
PPT
Mvc architecture
PPTX
reactJS
PPTX
Angular 2.0 forms
PPTX
Angular overview
PPT
ASP.NET MVC Presentation
PPTX
[Final] ReactJS presentation
PDF
ReactJS presentation
PPTX
Introduction to MERN
PPTX
Angular 5 presentation for beginners
PDF
Angular Directives | Angular 2 Custom Directives | Angular Tutorial | Angular...
PDF
Nodejs presentation
PPTX
Introduction to ajax
TypeScript
Angular Data Binding
Angular data binding
Angular - Chapter 7 - HTTP Services
Intro to React
Introduction to angular with a simple but complete project
Express js
Modules in AngularJs
Mvc architecture
reactJS
Angular 2.0 forms
Angular overview
ASP.NET MVC Presentation
[Final] ReactJS presentation
ReactJS presentation
Introduction to MERN
Angular 5 presentation for beginners
Angular Directives | Angular 2 Custom Directives | Angular Tutorial | Angular...
Nodejs presentation
Introduction to ajax
Ad

Similar to AngularJS (20)

PPTX
Angular js
PPTX
Angular js
PPTX
Dive into Angular, part 1: Introduction
PPTX
Angular Presentation
PPTX
Intoduction to Angularjs
PDF
Everything You Need To Know About AngularJS
PPTX
Angular workshop - Full Development Guide
PDF
AngularJS: Overview & Key Features
PPTX
Angular js
PDF
AngularJS Workshop
PPTX
Introduction to AngularJs
PPTX
The AngularJS way
PDF
AngularJS By Vipin
PPTX
Angular patterns
PPT
Coffee@DBG - Exploring Angular JS
PDF
AngularJS Basics
PPTX
PPTX
AngularJs
PPTX
Angular js 1.0-fundamentals
Angular js
Angular js
Dive into Angular, part 1: Introduction
Angular Presentation
Intoduction to Angularjs
Everything You Need To Know About AngularJS
Angular workshop - Full Development Guide
AngularJS: Overview & Key Features
Angular js
AngularJS Workshop
Introduction to AngularJs
The AngularJS way
AngularJS By Vipin
Angular patterns
Coffee@DBG - Exploring Angular JS
AngularJS Basics
AngularJs
Angular js 1.0-fundamentals
Ad

More from NexThoughts Technologies (20)

PDF
PDF
Docker & kubernetes
PDF
Apache commons
PDF
Microservice Architecture using Spring Boot with React & Redux
PDF
Solid Principles
PDF
Introduction to TypeScript
PDF
Smart Contract samples
PDF
My Doc of geth
PDF
Geth important commands
PDF
Ethereum genesis
PPTX
Springboot Microservices
PDF
An Introduction to Redux
PPTX
Google authentication
Docker & kubernetes
Apache commons
Microservice Architecture using Spring Boot with React & Redux
Solid Principles
Introduction to TypeScript
Smart Contract samples
My Doc of geth
Geth important commands
Ethereum genesis
Springboot Microservices
An Introduction to Redux
Google authentication

Recently uploaded (20)

PDF
Transforming Manufacturing operations through Intelligent Integrations
PDF
cuic standard and advanced reporting.pdf
PDF
Sensors and Actuators in IoT Systems using pdf
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
PPTX
Big Data Technologies - Introduction.pptx
PPTX
Spectroscopy.pptx food analysis technology
PDF
KodekX | Application Modernization Development
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
Electronic commerce courselecture one. Pdf
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PDF
Advanced Soft Computing BINUS July 2025.pdf
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
madgavkar20181017ppt McKinsey Presentation.pdf
PDF
Advanced IT Governance
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PPTX
breach-and-attack-simulation-cybersecurity-india-chennai-defenderrabbit-2025....
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Transforming Manufacturing operations through Intelligent Integrations
cuic standard and advanced reporting.pdf
Sensors and Actuators in IoT Systems using pdf
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Diabetes mellitus diagnosis method based random forest with bat algorithm
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
Big Data Technologies - Introduction.pptx
Spectroscopy.pptx food analysis technology
KodekX | Application Modernization Development
NewMind AI Weekly Chronicles - August'25 Week I
Electronic commerce courselecture one. Pdf
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
Advanced methodologies resolving dimensionality complications for autism neur...
Advanced Soft Computing BINUS July 2025.pdf
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
madgavkar20181017ppt McKinsey Presentation.pdf
Advanced IT Governance
The Rise and Fall of 3GPP – Time for a Sabbatical?
breach-and-attack-simulation-cybersecurity-india-chennai-defenderrabbit-2025....
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx

AngularJS

  • 2. AngularJS from novice to professional
  • 3. Agenda 1. What is AngularJS? 2. Core features 3. It's working 4. How to start working with it? 5. Controller 6. AngularJS directives 7. Expression 8. Forms 9. Services
  • 4. Agenda 10. Modules 9. Routing 10. Scope 11. Dependency Injection 12. Filters 13. Advantages and disadvantages 14. References 15. Q/A 16. Quiz
  • 5. What's AngularJS? AngularJS (commonly referred to as "Angular") is an open-source web application framework maintained by Google to address many of the challenges encountered in developing single-page applications. It aims to simplify both the development and the testing of such applications by providing a framework for client-side model–view–controller (MVC) – As per Wikipedia.
  • 6. Core features 1.Two way data binding 2.Templates 3.Model view controller(MVC) 4.Dependency Injection
  • 7. Two Way Data Binding
  • 8. Templates  In AngularJS, a template is just plain-old-HTML. The HTML vocabulary is extended, to contain instructions on how the model should be projected into the view.  The HTML templates are parsed by the browser into the DOM. The DOM then becomes the input to the AngularJS compiler. AngularJS traverses the DOM template for rendering instructions, which are called directives. Collectively, the directives are responsible for setting up the data-binding for your application view.
  • 12. Hello World - AngularJS
  • 14. AngularJS Directives  ng-app: Declares an element as root element  ng-bind: Automatically changes the text of HTML element  ng-model: Similar to ng-bind but allow two way binding  ng-class: Allow class attribute to be dynaically loaded  ng-controller: Specifies javascript controller class  ng-repeat: Instantiate an element once per item from a collection  ng-show & ng-hide: Conditionally show or hide an element  ng-switch: Conditionally instantiate one template from a list  ng-view: Rendering templates driven by specific controllers  ng-if: Simple if-else attribute that we know from ever!
  • 16. Angular Form Properties $valid, $invalid, $pristine, $dirty Angular also provides classes on the form and its inputs so that you can style each state accordingly.
  • 17. AngularJS Services In Angular a service is a function or an object and is used to share data and/or behavior across controllers, directives, filters, other services etc. A service is treated as a singleton, that is there is only one instance of a specific service available during the whole lifetime of the Angular application. This is different from e.g. a controller of which many instances can be created. The easiest way is to use the Service recipe of an angular module. var app = angular.module('app', []); app.service('some-service', function(){…}); Other two methods/way to create service are: 1. The factory recipe 2.The provider recipe
  • 21. AngularJS Dependency Injection AngularJS has a built-in dependency injection subsystem that helps the developer by making the application easier to develop, understand, and test. Dependency Injection (DI) allows you to ask for your dependencies, rather than having to go look for them or make them yourself. Think of it as a way of saying "Hey I need X', and the DI is responsible for creating and providing it for you. To gain access to core AngularJS services, it is simply a matter of adding that service as a parameter; AngularJS will detect that you need that service and provide an instance for you.
  • 22. AngularJS Filters Angular exposes a simple API for creating a filter. Just as you would declare a controller with app.controller(‘myCtrl', function(){});, you can create a new filter by appending .filter(‘filterName', function(){}) to your Angular app.
  • 23. AngularJS Advantages  Super fast development  Makes developing SPA easy  Awesome performance  Make apps scalable  Data binding and DOM manipulation
  • 24. AngularJS Disadvantages  Good for I/O driven apps only(not games)  Angular is big and complicated. With multiple ways to do the same thing it is hard to tell which way is better for particular task.  The lifecycle of Angular application is complex, and to master it you really need to read the code.
  • 25. References  AngularJS Docs(https://docs.angularjs.org/tutorial)  AngularJS API Reference(https://docs.angularjs.org/api)  AngularJS Code School(http://angular.codeschool.com/)  ng-newsletter(http://www.ng-newsletter.com/books/)
  • 26. Discussion Session QUERIES ? Hiten Pratap Singh http://github.com/hitenpratap http://hprog99.wordpress.com
  • 27. Quiz Time Anyone have any suggestons about what it should be? If no then We'll build an online contact manager just like Google Contact.