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
Composing Reactive Software
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
michaelavila
July 28, 2017
Programming
87
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Composing Reactive Software
michaelavila
July 28, 2017
More Decks by michaelavila
See All by michaelavila
Navigating in VIM
michaelavila
0
99
Other Decks in Programming
See All in Programming
AgentCore CLI で進化した AWS での AI エージェントの作り方 : 必要な機能を必要な時に
icoxfog417
PRO
3
370
TiDB Cloudのカスタムコントローラーによるオートスケール対応
takaidohigasi
0
130
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
270
SREの越境 / SRE Collaboration
y0hgi
2
270
スマート反転とウェブアクセシビリティ
camiha
0
210
『寄り添うラジオ』をAIで作る 体験価値から逆算した、会話しないUXと品質設計
theoriatec2024
3
180
AI × TiDD / 2026.09.05 Redmine 大阪
tokudiro
1
180
The Good Stuff, Not the Slop: Engineering High-Quality Android Apps with Modern AI Tooling
danybony
1
260
IBM Bob Dojo #1 仕様駆動開発入門
oniak3ibm
PRO
0
170
テストを司るデーモンに会いに行く 〜隔離した仮想マシンでテストを通すまで〜
h1d3mun3
1
560
What We Talk About When We Talk About XP
m_seki
2
680
海上で動くGoサーバー: goroutineとchannelでさばく航行データストリーム
atsuki_seo
0
910
Featured
See All Featured
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
6.1k
The Organizational Zoo: Understanding Human Behavior Agility Through Metaphoric Constructive Conversations (based on the works of Arthur Shelley, Ph.D)
kimpetersen
PRO
0
460
Game over? The fight for quality and originality in the time of robots
wayneb77
1
290
Test your architecture with Archunit
thirion
2
2.4k
The World Runs on Bad Software
bkeepers
PRO
72
12k
Building a Scalable Design System with Sketch
lauravandoore
464
34k
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.8k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
Impact Scores and Hybrid Strategies: The future of link building
tamaranovitovic
0
440
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.3k
How to Grow Your eCommerce with AI & Automation
katarinadahlin
PRO
2
280
Transcript
carbonfive.com Composing Reactive Software Michael Avila •
[email protected]
Agenda • Insufficient overview • Important, but poorly explained idea
• Vague and unjustified conclusion • Questions
Agenda (revised) • Reactive Programming • Signal Graph • Conclusion
• Questions
Reactive Programming
“... programming with asynchronous data streams ...”
interface Observable<T> { subscribe( onNext: (T) => void, onError: (Error)
=> void, onCompleted: () => void, ): Subscription; map( (T) => V): Observable<V>; flatMap((T) => Observable<V>): Observable<V>; scan( (V, T) => V, V): Observable<V>; filter( (T) => boolean): Observable<T>; withLatestFrom(Observable<V>, ...): Observable<[T, V, ...]>; combineLatest( Observable<V>, ...): Observable<[T, V, ...]>; … any many more! }
Operators buffer bufferCount bufferTime bufferToggle bufferWhen combineAll combineLatest concat concatAll
concatMap concatMapTo count debounce debounceTime defaultIfEmpty delay delayWhen dematerialize distinctUntilChanged do every expand filter first groupBy ignoreElements last let map mapTo merge mergeMap partition pluck publish race repeat retry retryWhen sample scan share single skip skipUntil skipWhile startWith switchMap window windowCount windowTime windowToggle windowWhen withLatestFrom zip … and probably more
const email$ = Observable.fromEvent(...<input/>...); const password$ = Observable.fromEvent(...<input/>...); const login$
= Observable.fromEvent(...<button/>...); const activeUser = login$ .withLatestFrom(email$, password$) .flatMap(([_, email, password]) => { return Observable.ajax.post('/auth/', { email, password }) .map(({ response }) => response); }); activeUser.subscribe(...<div>...);
None
None
None
Signal Graph
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
Additional Notes ➔ Asynchronous ➔ Lazy* ➔ Composable
None
Good?
None
¯\_(ツ)_/¯
Good! I think.
carbonfive.com Thanks!