Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Databinding in Angular 2
Search
Manfred Steyer
PRO
October 25, 2016
Programming
0
230
Databinding in Angular 2
Manfred Steyer
PRO
October 25, 2016
Tweet
Share
More Decks by Manfred Steyer
See All by Manfred Steyer
Nostalgia Meets Technology: Super Mario with TypeScript
manfredsteyer
PRO
0
19
Full Cycle Reactivity in Angular: SignalStore mit Signal Forms und Resources
manfredsteyer
PRO
0
16
Premier Disciplin for Micro Frontends Multi Version/ Framework Scenarios @OOP 2026, Munic
manfredsteyer
PRO
0
200
Beyond the Basics: Signal Forms
manfredsteyer
PRO
0
110
360° Signals in Angular: Signal Forms with SignalStore & Resources @ngLondon 01/2026
manfredsteyer
PRO
0
200
All About Angular‘s New Signal Forms
manfredsteyer
PRO
0
37
Full-Cycle Reactivity in Angular: SignalStore mit Signal Forms und Resources
manfredsteyer
PRO
0
290
Your Architecture as a Crime Scene?Forensic Analysis
manfredsteyer
PRO
0
200
Full-Cycle Reactivity in Angular: SignalStore mit Signal Forms und Resources
manfredsteyer
PRO
0
300
Other Decks in Programming
See All in Programming
The Ralph Wiggum Loop: First Principles of Autonomous Development
sembayui
0
3.7k
今更考える「単一責任原則」 / Thinking about the Single Responsibility Principle
tooppoo
3
1.3k
CSC307 Lecture 12
javiergs
PRO
0
450
Claude Code の Skill で複雑な既存仕様をすっきり整理しよう
yuichirokato
1
240
What Spring Developers Should Know About Jakarta EE
ivargrimstad
0
150
ご飯食べながらエージェントが開発できる。そう、Agentic Engineeringならね。
yokomachi
1
280
New in Go 1.26 Implementing go fix in product development
sunecosuri
0
200
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
170
CSC307 Lecture 11
javiergs
PRO
0
580
RAGでハマりがちな"Excelの罠"を、データの構造化で突破する
harumiweb
8
2.3k
CSC307 Lecture 10
javiergs
PRO
1
690
NOT A HOTEL - 建築や人と融合し、自由を創り出すソフトウェア
not_a_hokuts
2
520
Featured
See All Featured
Fireside Chat
paigeccino
41
3.8k
Getting science done with accelerated Python computing platforms
jacobtomlinson
2
130
Beyond borders and beyond the search box: How to win the global "messy middle" with AI-driven SEO
davidcarrasco
3
65
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
1
360
YesSQL, Process and Tooling at Scale
rocio
174
15k
Mind Mapping
helmedeiros
PRO
1
110
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
290
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3.3k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
2.7k
We Analyzed 250 Million AI Search Results: Here's What I Found
joshbly
1
860
WENDY [Excerpt]
tessaabrams
9
36k
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
71
Transcript
Data Binding in Angular 2 Manfred Steyer
About me … • Manfred Steyer • SOFTWAREarchitekt.at • Trainer
& Consultant • GDE and MVP • Focus: Angular Page 2 Manfred Steyer
Data Binding in AngularJS 1.x Page 4 Model Model
Directive Nearly everything can depend on everything Leads to serveral digest cycles
Angular 2 Page 5 Component for whole App Component
(e. g. list) Component (e. g. list-item) Component (e. g. list-item)
Property Binding (One Way, Top/Down) Page 6 model item
item {{ item.title }} {{ item.title }} [http://victorsavkin.com/post/110170125256/change-detection-in-angular-2]
Property Binding (One Way, Top/Down) • Only one digest cycle
needed • Child component must not modify parent component (e. g. by using setters) • Angular 2 checks for this in dev mode
Event Bindings (One Way, Bottom/Up) Page 8 {{ item.title
}} {{ item.title }} Event-Handler Event-Handler
Event Bindings (One Way, Bottom/Up) • No digest cycle for
propagating events • But: Events can change state Updating Property Bindings Page 9
Property and Event Bindings Page 10 Performing Property Bindings
Executing Event Handlers Event occurs App is ready All handlers executed Properties bound
Two Way Binding Page 11 <input [(ngModel)]="from">
Two Way = Property and Event Bindings Page 12
<input [ngModel]="from" (ngModelChange)="from = $event"> Property + Change changed value
Summary • Property Binding: One Way; Top/Down • Event Binding:
One Way; Bottom/Up • Two Way = Property Binding + Event Binding • Conventions for Two Way Binding • Align to this conventions in own components Page 13
Contact [mail]
[email protected]
[blog] SOFTWAREarchitekt.at [twitter] ManfredSteyer