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
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
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Awaiting for Rx
Search
Ana Betts
December 04, 2013
Technology
600
4
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Awaiting for Rx
How to use Rx along with async/await, presented at NDC London
Ana Betts
December 04, 2013
More Decks by Ana Betts
See All by Ana Betts
Flutter in Practice
anaisbetts
2
190
Electron Pro-Tips
anaisbetts
0
230
Electron: The Boring Parts
anaisbetts
1
450
Why Akavache is Fast: How not to use sqlite3
anaisbetts
0
220
Native Modules in Electron
anaisbetts
3
8.4k
Single Page Apps in Electron
anaisbetts
3
1.5k
Functional Reactive Programming in Practice
anaisbetts
2
360
On Programming
anaisbetts
3
410
MVVM Without XAML
anaisbetts
3
750
Other Decks in Technology
See All in Technology
AWS DevOps Agentはどこまで任せられるか 〜機能の現在地と、機能拡張の実践〜
nyankotaro
0
170
「Learning Outcome」を書きたくない私が、Learning Outcomeと折り合いをつけるまで
mhlyc
0
150
プロダクトが成長すると、 プロダクトマネージャーの仕事はどう変わるのか - 「まず作る」から「小さく学び、確かめながら進む」へ
sansantech
PRO
0
120
その Valkey 使いこなしていますか?
onk
PRO
5
1.9k
AIをリアル世界に解き放つ 〜M5Stack×AIであなたのアイディアを手の平に〜
hamadakoji
1
400
AI時代のGraphQL
joere
3
370
Temporal 最高!でも改めて「日付」について調べたら人類の負債すぎる件
riyaamemiya
0
230
React改造してみた
tsukina_7mochi
0
160
How to Design Configuration for Rails Applications
willnet
1
1.1k
AWSDirectConnectの構築の進め方を整理してみた
masa_my
1
160
dbt Semantic Layerで進めるenechainのデータ民主化
akizhou
1
240
Microsoft のサポート ライフサイクルを理解する
murachiakira
PRO
0
140
Featured
See All Featured
Mobile First: as difficult as doing things right
swwweet
225
10k
Money Talks: Using Revenue to Get Sh*t Done
nikkihalliwell
0
530
The Language of Interfaces
destraynor
162
27k
More Than Pixels: Becoming A User Experience Designer
marktimemedia
3
570
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
jQuery: Nuts, Bolts and Bling
dougneiner
66
8.6k
コードの90%をAIが書く世界で何が待っているのか / What awaits us in a world where 90% of the code is written by AI
rkaga
63
47k
Pawsitive SEO: Lessons from My Dog (and Many Mistakes) on Thriving as a Consultant in the Age of AI
davidcarrasco
0
260
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
560
The innovator’s Mindset - Leading Through an Era of Exponential Change - McGill University 2025
jdejongh
PRO
1
380
Art, The Web, and Tiny UX
lynnandtonic
304
22k
Designing for Performance
lara
612
70k
Transcript
Awaiting for Rx: ! A Play in Five Acts
/paulcbetts
Why Rx?
None
code is communication between people ! (that incidentally, also runs
on a computer)
await doesn’t help you get away from state
tasks don’t help you with events
Rx in 5 minutes
IObservable is a better event
None
events are lists
observable as timeline OnNext OnNext OnNext OnCompleted ‘A’ ‘B’ ‘C’
OnError!
tasks are just events that happen once
task as observable ‘A’ Task.Run(() => /*…*/)
None
+ Task<T>
you
can
await
IObservable
None
None
the catch
you must guarantee that the IObservable terminates
None
The two ways to make things awaitable: Take and Aggregate
None
someTask.ToObservable(); <=> someObservable.ToTask();
None
None
async-friendly Rx operators SelectMany Create Defer Switch IScheduler.Schedule StartAsync Using
Concat Merge
await often introduces unnecessary ordering constraints
None
None
this is MapReduce (or in C# lingo, SelectAggregate™)
None
always use Rx for UI events
always use Rx for UI events
ಠ_ಠ
always use Rx for UI events
None
None
describing an entire process in one place is the goal
None
describing an entire process in one place is the goal
Rx is particularly good at describing pipelines of data
declarative, functional code is easier to test
imperative await methods get the job done
None
None
None
use extensions to provide Task-friendly apis
None
None
– the average developer “hwæt.”
None
None
None
Rx makes testing eas(ier)
None
None
test ordering, not concurrency
None
None
Thanks!