Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
3 Effective Rules for Using Signals in Angular
Search
Manfred Steyer
PRO
November 09, 2024
Programming
450
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
3 Effective Rules for Using Signals in Angular
Manfred Steyer
PRO
November 09, 2024
More Decks by Manfred Steyer
See All by Manfred Steyer
Agentic UI with Open Standards @ngGraz Sep 2026
manfredsteyer
PRO
0
24
Agentic UI with Open Standards @GDG Salzburg, Bgl & Prishtina
manfredsteyer
PRO
0
47
Generative UI & AI-Assistants for Your Angular Solutions
manfredsteyer
PRO
1
490
Generative UI & AI-Assistants for Your Angular Solutions
manfredsteyer
PRO
0
200
Nostalgia Meets Technology: Super Mario with TypeScript
manfredsteyer
PRO
0
290
Signal Forms: Details & Live Coding @enterJS 2026 in Mannheim
manfredsteyer
PRO
0
300
Strategic Design in the Frontend: Moduliths & Micro Frontends @DDDEurope
manfredsteyer
PRO
0
210
Agentic UI
manfredsteyer
PRO
0
310
Signal Forms: Beyond the Basics @ngBaguette 2026 in Paris
manfredsteyer
PRO
0
350
Other Decks in Programming
See All in Programming
Gmail/Google DriveをトリガーにAIエージェントを動かそう! / Run AI agents with Gmail/Google Drive as triggers!
har1101
3
480
Building an Out-of-Order CPU
latte72
1
730
ソフトウェアラスタライザ
fadis
1
800
FastAPI の並行処理モデルを完全に理解する
hoto17296
9
3.8k
GKE アップグレード前に知っておきたい Blue/Green と PDB の関係
stkk
0
160
一参加者から『中の人』へ 〜全通PHPerがブースに立って学んだ、カンファレンスを100倍楽しむコツ〜
wp_daisuke
0
130
Intent as Code
shoppingjaws
3
510
go-spidermonkeyでAIエージェントのCode Modeを実装する
syumai
3
1.5k
Webの地図
yosuke_furukawa
PRO
3
2.6k
巨大モノリシックアプリ モダン化大作戦
ktcryomm
0
140
Family mrubyの進捗
kishima
1
100
AI時代に学ぶ 好きなルール 嫌いなルール Linter編
shorty5121
0
890
Featured
See All Featured
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.8k
The Spectacular Lies of Maps
axbom
PRO
1
980
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
330
The Cult of Friendly URLs
andyhume
79
7k
Building a Modern Day E-commerce SEO Strategy
aleyda
45
9.2k
Agile Leadership in an Agile Organization
kimpetersen
PRO
0
230
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4.2k
Optimising Largest Contentful Paint
csswizardry
37
3.9k
Ecommerce SEO: The Keys for Success Now & Beyond - #SERPConf2024
aleyda
1
2.1k
BBQ
matthewcrist
89
10k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
232
55k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
10
1.3k
Transcript
AngularArchitects.io | @ManfredSteyer | @RainerHahnekamp 3 Effective Rules for Using
Signals in Angular Karlsruhe 2024
None
None
None
Agenda • Austrian Desserts • Computed • Resource API •
Effects • Stores
Result 3 Rules (of thumb)
About me… Manfred Steyer, ANGULARarchitects.io (Remote) Angular Workshops and Consulting
Google Developer Expert for Angular Blog, Books, Articles, and Talks about Angular Manfred Steyer
Austrian Desserts: Example App
Demo
Simple Reactivity with Signals Signal 4711 Consumer read set notify
4712
Change Detection with Signals Signal
Component With Signals desserts = signal<Dessert[]>([]); const result = await
this.dessertService.findAsPromise(originalName); this.desserts.set(result); @for (d of desserts(); track d.id) { <dessert-card [item]="d" /> }
Computed: Extremely Underrated!
Reactive Programming: Paradigm Shift!
Marble Run
Marble Run Data Binding
Reactive Flow with Computed desserts = signal<Dessert[]>([]); ratings = signal<DessertIdToRatingMap>({});
ratedDesserts = computed(() => this.toRated(this.desserts(), this.ratings()));
Reactive Flow with Computed desserts = signal<Dessert[]>([]); ratings = signal<DessertIdToRatingMap>({});
ratedDesserts = computed(() => this.toRated(this.desserts(), this.ratings()));
Demo Branch: 02a-input-signals
Reactive Flow with Computed desserts = signal<Dessert[]>([]); ratings = signal<DessertIdToRatingMap>({});
ratedDesserts = computed(() => this.toRated(this.desserts(), this.ratings())); originalName = signal(''); englishName = signal(''); Load Desserts
Resource API
Resource API dessertsResource = resource({ request: this.dessertsCriteria, loader: (param) =>
{ return this.#dessertService.findPromise(param.request); } }); Experimental in Angular 19
Resource API dessertsResource = resource({ request: this.dessertsCriteria, loader: (param) =>
{ return this.#dessertService.findPromise(param.request); } }); dessertsCriteria = computed(() => ({ originalName: this.originalName(), englishName: this.englishName(), })); desserts = this.dessertsResource.value; ratedDesserts = computed(() => this.toRated(this.desserts, …));
Resource Prevents Race Conditions Pancakes Sacher Cake Ice Cream Pancakes
Resource Prevents Race Conditions Pancakes Sacher Cake Ice Cream Pancakes
„switchMap semantics“
Demo Branch: 2c-resource
Demo Branch: 2e-resource
Architecture Rule #1 Derive state where possible
Effects
Connecting Reactive and Imperative World
None
Ideal-typical Tasks • Drawing on a canvas • Manual DOM
manipulations • Logging • Synching with LocalStore Stuff, you cannot do with data binding Rendering (and similar tasks …)
Demo Branch: 04c-effects
Architecture Rule #2 Avoid effects propagating state and Signal writes
Instead: Reactive Helpers like Resource API @ngrx/signals ngxtension Your Own
…
Demo Branch: 08b-details
Reactive Helpers: Effects Under the Hood
Stores
None
None
None
Stores Streamline Reactive Flow Component Store "Intention" Signal sync/ async
computed() computed()
Demo Branch: 08b-details
Architecture Rule #3 Stores make your reactive flow more manageable
Free eBook (6th Edition) angularArchitects.io/ebook
Conclusion Architecture Rule #1 Derive state where possible Architecture Rule
#2 Avoid effects propagating state and Signal writes Architecture Rule #3 Stores make your reactive flow more manageable
None
Marble Run
AngularArchitects.io Slides & Examples ManfredSteyer