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
Awaiting for Rx
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
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
220
Electron: The Boring Parts
anaisbetts
1
430
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
350
On Programming
anaisbetts
3
400
MVVM Without XAML
anaisbetts
3
730
Other Decks in Technology
See All in Technology
修正PRを食べてレビュースキルが賢くなる:Claude Codeによる自己改善サイクル
yuyaumetsu
4
1.2k
Webアクセシビリティ入門 2026
recruitengineers
PRO
1
290
AIが自社のTableauを操作する世界へ:Tableau MCP超入門
tbtykk
0
110
20260608_Codexの可能性_ノンプログラマー向け_大城追記
doradora09
PRO
0
760
【CEDEC2026】『Relink』を拡張せよ - 『GRANBLUE FANTASY: Relink - Endless Ragnarok』の開発速度と品質を守るCI運用
cygames
PRO
0
120
Pavlokで始める電撃駆動開発
sgrsn
0
170
Sansan Engineering Unit 紹介資料
sansan33
PRO
1
4.9k
最高のシステムプロンプトを作るためにフィードバック機能を導入した話
alchemy1115
1
330
Breaking the Seal: Static Deobfuscation of Compiled V8 JavaScript Bytecode Malware
hshrzd
0
480
制約理論(ToC)入門 2026版
recruitengineers
PRO
4
840
Goでデータパイプラインを作ろう
sansantech
PRO
0
250
え?フロントエンドエンジニアの ワイがインフラも!?
puku0x
0
280
Featured
See All Featured
Build your cross-platform service in a week with App Engine
jlugia
234
19k
Color Theory Basics | Prateek | Gurzu
gurzu
0
410
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
460
Noah Learner - AI + Me: how we built a GSC Bulk Export data pipeline
techseoconnect
PRO
0
350
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
200
Neural Spatial Audio Processing for Sound Field Analysis and Control
skoyamalab
0
400
Getting science done with accelerated Python computing platforms
jacobtomlinson
2
390
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
610
4 Signs Your Business is Dying
shpigford
187
22k
What does AI have to do with Human Rights?
axbom
PRO
1
2.3k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
254
22k
A designer walks into a library…
pauljervisheath
211
24k
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!