SlideShare a Scribd company logo
Angular
Angular Expressions
$interopolateProvieder
Undefined / Null
$eval()
2-Way Data Binding
<div>{{ username }}</div>
angular.module('opentalks')
.controller('UserController', ['$scope', function($scope){
$scope.username = "Someone :D";
}]);
<input type="text" ng-model="username" />
angular.module('opentalks')
.controller('UserController', ['$scope', function($scope){
$scope.$watch('username', function(newVal, oldVal){
...
console.log("Username has been changed!");
};
}]);
Filters
Pipes In Linux
|
ls | “ ”grep something
<div>{{ username }}</div>
<div>{{ username | uppercase }}</div>
Custom Filter
angular.module('opentalks')
.filter(...);
angular.module('opentalks')
.filter('opentalks', ...);
angular.module('opentalks')
.filter('opentalks', function(){
….
});
angular.module('opentalks')
.filter('opentalks', function(){
return function(){
….
};
});
angular.module('opentalks')
.filter('opentalks', function(){
return function(input){
};
});
angular.module('opentalks')
.filter('opentalks', function(){
return function(input){
return 'output';
};
});
angular.module('opentalks')
.filter('opentalks', function(){
return function(input, arg1, arg2, ...){
return 'output';
};
});
angular.module('opentalks')
.filter('opentalks', function(Dependencies){
return function(input, arg1, arg2, ...){
return 'output';
};
});
<div>{{ username | opentalks }}</div>
<div>{{ username | opentalks:'arg1' }}</div>
<div>{{ username | opentalks:'arg1':'arg2' }}</div>
Filters in
{ , , ...Controllers Services }
Angular.modeule('opentalks')
.controller('OpentalksController', function(opentalksopentalksFilterFilter)
{
}
Angular.modeule('opentalks')
.controller('OpentalksController', function(opentalksFilter)
{
var output = opentalksFilteropentalksFilter(input, arg1, arg2)(input, arg1, arg2);;
}
Services
Reusability
Singleton
. ( )angular module 'opentalks'
.factory(...);
. ( )angular module 'opentalks'
. (factory 'OpentalksPeople', ...);
. ( )angular module 'opentalks'
. ( ,factory 'OpentalksPeople' (){function
...
});
. ( )angular module 'opentalks'
. ( , (factory 'OpentalksPeople' function Dependencies)
{
{return
....
};
});
. ( )angular module 'opentalks'
. ( , (){factory 'OpentalksPeople' function
{return
....
};
});
. ( )angular module 'opentalks'
. ( , (){factory 'OpentalksPeople' function
()return new Aservice ;
});
. ( )angular module 'opentalks'
. ( , (){factory 'OpentalksPeople' function
return 'Or even a string';
});
. ( )angular module 'opentalks'
. ( , (){factory 'OpentalksPeople' function
return 123465798;
});
Revealing Module Pattern
. ( )angular module 'opentalks'
. ( , ( )factory 'OpentalksPeople' function Dependencies
{
...
= (){...}aPublicfunction function
= (){...}aPrivateFunction function
...
{return
:aMethod somePublicfunction
};
});
. ( )angular module 'opentalks'
.service(...);
. ( )angular module 'opentalks'
. (service 'OpentalksPeople', ...);
. ( )angular module 'opentalks'
. ( ,service 'OpentalksPeople' (){function
...
});
. ( )angular module 'opentalks'
. ( ,service 'OpentalksPeople' (){function
...
});
. ( )angular module 'opentalks'
. ( , (){service 'OpentalksPeople' function
. = (){}this somemethod function ;
…
});
. ( )angular module 'opentalks'
. ( , (service 'OpentalksPeople' function Dependencies)
{
. = (){}this somemethod function ;
...
});
Configurable?
Providers
Accessible in Config Phase
As a Service
. ( )angular module 'opentalks'
.provider(...);
. ( )angular module 'opentalks'
. (provider 'TabrizOpentalks', ...);
. ( )angular module 'opentalks'
. ( ,provider 'OpentalksWebsite' (){function
....
. = (){...}this setCity function ;
});
. ( )angular module 'opentalks'
. ( , (){provider 'OpentalksWebsite' function
....
. = (){...}this $get function
});
. ( )angular module 'opentalks'
. ( , (){provider 'OpentalksWebsite' function
....
. = (this $get function ServiceDependencies){ ... }
});
Using In Config Phase
. ( )angular module 'opentalks'
. ( (config function OpentalksWebsiteProviderProvider){
. ( )OpentalksWebsiteProvider setCity 'Tabriz' ;
});
Using As A Service
. ( )angular module 'opentalks'
. ( ,controller 'CityController'
(function OpentalksWebsite){
...
});
Directives
Teaching HTML New Tricks
DOM Manipulation
jqLite
-Angular UI
<div -ng repeat="person in opentalks">
{{ }}person
/< div>
<pagination ... />< pagination>
<button -ng click= ("someFunction ' :D:D ) /' ">< button>
HTML5 Compliance
data-{attribute-name}
x-{attribute-name}
Imperative
.vs
Declarative
=<div id "username /">< div>
...
. (document getElementById 'username ). =' innerHTML
, , !'My username not yours goes here ';
{{<div> username }} /< div>
=”<div id pagination” />< div>
….
= . (var pagination document getElementById 'pagination )' ;
...
<pagination currentPage=”139”></pagination>
Dependency Injection
Form Validation
<form name="opentalks">
...
/< form>
.opentalks $valid
.opentalks $invalid
.opentalks $pristine
.opentalks $dirty
<form name="opentalks">
<input name=” ”username ...required />
/< form>
.opentalks username.$pristine
. .opentalks username .{...}$error
=” ”<input name username minlength=”5” />
=” ”<input name username pattern=”A Pattern :D” />
Minification
ngmin
. ( , (controller 'SomeCtrl' function $scope){
...
});
. ( ,controller 'SomeCtrl' ['$scope', (function $scope){
...
}]);
-Angular seed
...Debuging
Unminified Version
AngularJs Batarang
SEO
Search Engine Crawlers
.prerender io
.getseojs com

More Related Content

What's hot (20)

PDF
Your Entity, Your Code
Marco Vito Moscaritolo
 
PDF
Workshop 5: JavaScript testing
Visual Engineering
 
PPTX
AngularJS - $http & $resource Services
Eyal Vardi
 
PDF
Angular js routing options
Nir Kaufman
 
PPTX
Performance Optimization In Angular 2
Eyal Vardi
 
PDF
Min-Maxing Software Costs - Laracon EU 2015
Konstantin Kudryashov
 
PDF
Min-Maxing Software Costs
Konstantin Kudryashov
 
PPTX
Modules and injector
Eyal Vardi
 
PDF
前端MVC 豆瓣说
Ting Lv
 
PDF
Functionality Focused Code Organization
Rebecca Murphey
 
PDF
Angular Promises and Advanced Routing
Alexe Bogdan
 
PDF
Backbone Basics with Examples
Sergey Bolshchikov
 
KEY
Advanced jQuery
sergioafp
 
PPTX
Angular 2 - Ahead of-time Compilation
Eyal Vardi
 
PDF
Chaining and function composition with lodash / underscore
Nicolas Carlo
 
PDF
Backbone.js — Introduction to client-side JavaScript MVC
pootsbook
 
PDF
Decoupling with Design Patterns and Symfony2 DIC
Konstantin Kudryashov
 
PDF
CQRS and Event Sourcing in a Symfony application
Samuel ROZE
 
PDF
Building Large jQuery Applications
Rebecca Murphey
 
PDF
Mulberry: A Mobile App Development Toolkit
Rebecca Murphey
 
Your Entity, Your Code
Marco Vito Moscaritolo
 
Workshop 5: JavaScript testing
Visual Engineering
 
AngularJS - $http & $resource Services
Eyal Vardi
 
Angular js routing options
Nir Kaufman
 
Performance Optimization In Angular 2
Eyal Vardi
 
Min-Maxing Software Costs - Laracon EU 2015
Konstantin Kudryashov
 
Min-Maxing Software Costs
Konstantin Kudryashov
 
Modules and injector
Eyal Vardi
 
前端MVC 豆瓣说
Ting Lv
 
Functionality Focused Code Organization
Rebecca Murphey
 
Angular Promises and Advanced Routing
Alexe Bogdan
 
Backbone Basics with Examples
Sergey Bolshchikov
 
Advanced jQuery
sergioafp
 
Angular 2 - Ahead of-time Compilation
Eyal Vardi
 
Chaining and function composition with lodash / underscore
Nicolas Carlo
 
Backbone.js — Introduction to client-side JavaScript MVC
pootsbook
 
Decoupling with Design Patterns and Symfony2 DIC
Konstantin Kudryashov
 
CQRS and Event Sourcing in a Symfony application
Samuel ROZE
 
Building Large jQuery Applications
Rebecca Murphey
 
Mulberry: A Mobile App Development Toolkit
Rebecca Murphey
 

Viewers also liked (13)

PPT
Lect24 handout
oyunbileg06
 
PPT
Angular Seminar-js
Mindfire Solutions
 
PPTX
Angular modules in depth
Christoffer Noring
 
PPTX
TDD Basics with Angular.js and Jasmine
Luis Sánchez Castellanos
 
PDF
AngularJS - What is it & Why is it awesome ? (with demos)
Gary Arora
 
PDF
Introduction To Single Page Application
KMS Technology
 
PDF
AngularJS application architecture
Gabriele Falace
 
PDF
Introduction to AngularJS
Jussi Pohjolainen
 
PPTX
Single Page Application (SPA) using AngularJS
M R Rony
 
PDF
AngularJS 101 - Everything you need to know to get started
Stéphane Bégaudeau
 
PPTX
AngularJS Architecture
Eyal Vardi
 
PDF
AngularJS Basics with Example
Sergey Bolshchikov
 
PPTX
Introduction to Angularjs
Manish Shekhawat
 
Lect24 handout
oyunbileg06
 
Angular Seminar-js
Mindfire Solutions
 
Angular modules in depth
Christoffer Noring
 
TDD Basics with Angular.js and Jasmine
Luis Sánchez Castellanos
 
AngularJS - What is it & Why is it awesome ? (with demos)
Gary Arora
 
Introduction To Single Page Application
KMS Technology
 
AngularJS application architecture
Gabriele Falace
 
Introduction to AngularJS
Jussi Pohjolainen
 
Single Page Application (SPA) using AngularJS
M R Rony
 
AngularJS 101 - Everything you need to know to get started
Stéphane Bégaudeau
 
AngularJS Architecture
Eyal Vardi
 
AngularJS Basics with Example
Sergey Bolshchikov
 
Introduction to Angularjs
Manish Shekhawat
 
Ad

Similar to AngularJs (20)

PPTX
AngularJS for Java Developers
Loc Nguyen
 
PPT
Coffee@DBG - Exploring Angular JS
Deepu S Nath
 
PPTX
AngularJs-training
Pratchaya Suputsopon
 
PPTX
Introduction to AngularJs
murtazahaveliwala
 
PPTX
Angular js introduction
Hsiu Shan
 
PDF
Introduction to AngularJS
Yoann Gotthilf
 
PDF
Workshop 12: AngularJS Parte I
Visual Engineering
 
PPTX
When to use and when not to use AngularJS - Liju Pillai, www.perfomatix.com
Perfomatix Solutions
 
PPTX
Basics of AngularJS
Filip Janevski
 
PPTX
AngularJS.part1
Andrey Kolodnitsky
 
PPTX
Exploring AngularJS - Liju Pillai
Liju Pillai
 
PPTX
Angular Presentation
Adam Moore
 
PDF
"Angular.js Concepts in Depth" by Aleksandar Simović
JS Belgrade
 
PPTX
Angular js
Behind D Walls
 
PPTX
The AngularJS way
Boyan Mihaylov
 
PDF
AngularJS - Services
Nir Kaufman
 
PDF
Everything You Need To Know About AngularJS
Sina Mirhejazi
 
PDF
Wt unit 5 client &amp; server side framework
PUNE VIDYARTHI GRIHA'S COLLEGE OF ENGINEERING, NASHIK
 
PDF
Mini-Training: AngularJS
Betclic Everest Group Tech Team
 
PPTX
Angular workshop - Full Development Guide
Nitin Giri
 
AngularJS for Java Developers
Loc Nguyen
 
Coffee@DBG - Exploring Angular JS
Deepu S Nath
 
AngularJs-training
Pratchaya Suputsopon
 
Introduction to AngularJs
murtazahaveliwala
 
Angular js introduction
Hsiu Shan
 
Introduction to AngularJS
Yoann Gotthilf
 
Workshop 12: AngularJS Parte I
Visual Engineering
 
When to use and when not to use AngularJS - Liju Pillai, www.perfomatix.com
Perfomatix Solutions
 
Basics of AngularJS
Filip Janevski
 
AngularJS.part1
Andrey Kolodnitsky
 
Exploring AngularJS - Liju Pillai
Liju Pillai
 
Angular Presentation
Adam Moore
 
"Angular.js Concepts in Depth" by Aleksandar Simović
JS Belgrade
 
Angular js
Behind D Walls
 
The AngularJS way
Boyan Mihaylov
 
AngularJS - Services
Nir Kaufman
 
Everything You Need To Know About AngularJS
Sina Mirhejazi
 
Wt unit 5 client &amp; server side framework
PUNE VIDYARTHI GRIHA'S COLLEGE OF ENGINEERING, NASHIK
 
Mini-Training: AngularJS
Betclic Everest Group Tech Team
 
Angular workshop - Full Development Guide
Nitin Giri
 
Ad

Recently uploaded (20)

PPTX
Webinar: Introduction to LF Energy EVerest
DanBrown980551
 
PDF
NewMind AI - Journal 100 Insights After The 100th Issue
NewMind AI
 
PPTX
UiPath Academic Alliance Educator Panels: Session 2 - Business Analyst Content
DianaGray10
 
PDF
Presentation - Vibe Coding The Future of Tech
yanuarsinggih1
 
PDF
Smart Trailers 2025 Update with History and Overview
Paul Menig
 
PDF
Log-Based Anomaly Detection: Enhancing System Reliability with Machine Learning
Mohammed BEKKOUCHE
 
PPTX
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
PDF
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
PDF
July Patch Tuesday
Ivanti
 
PDF
HubSpot Main Hub: A Unified Growth Platform
Jaswinder Singh
 
PDF
CIFDAQ Weekly Market Wrap for 11th July 2025
CIFDAQ
 
PPTX
Top iOS App Development Company in the USA for Innovative Apps
SynapseIndia
 
PDF
The Builder’s Playbook - 2025 State of AI Report.pdf
jeroen339954
 
PDF
New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
PDF
Chris Elwell Woburn, MA - Passionate About IT Innovation
Chris Elwell Woburn, MA
 
PDF
LLMs.txt: Easily Control How AI Crawls Your Site
Keploy
 
PDF
Exolore The Essential AI Tools in 2025.pdf
Srinivasan M
 
PDF
Transcript: New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
PDF
CIFDAQ Market Insights for July 7th 2025
CIFDAQ
 
PDF
HCIP-Data Center Facility Deployment V2.0 Training Material (Without Remarks ...
mcastillo49
 
Webinar: Introduction to LF Energy EVerest
DanBrown980551
 
NewMind AI - Journal 100 Insights After The 100th Issue
NewMind AI
 
UiPath Academic Alliance Educator Panels: Session 2 - Business Analyst Content
DianaGray10
 
Presentation - Vibe Coding The Future of Tech
yanuarsinggih1
 
Smart Trailers 2025 Update with History and Overview
Paul Menig
 
Log-Based Anomaly Detection: Enhancing System Reliability with Machine Learning
Mohammed BEKKOUCHE
 
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
July Patch Tuesday
Ivanti
 
HubSpot Main Hub: A Unified Growth Platform
Jaswinder Singh
 
CIFDAQ Weekly Market Wrap for 11th July 2025
CIFDAQ
 
Top iOS App Development Company in the USA for Innovative Apps
SynapseIndia
 
The Builder’s Playbook - 2025 State of AI Report.pdf
jeroen339954
 
New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
Chris Elwell Woburn, MA - Passionate About IT Innovation
Chris Elwell Woburn, MA
 
LLMs.txt: Easily Control How AI Crawls Your Site
Keploy
 
Exolore The Essential AI Tools in 2025.pdf
Srinivasan M
 
Transcript: New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
CIFDAQ Market Insights for July 7th 2025
CIFDAQ
 
HCIP-Data Center Facility Deployment V2.0 Training Material (Without Remarks ...
mcastillo49
 

AngularJs