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
Functional Reactive Programming
Search
Jason Orendorff
March 30, 2013
Programming
1k
9
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Functional Reactive Programming
Slides for a talk by Wilkes Joiner at Nashville Code Co-op Talk Day.
Jason Orendorff
March 30, 2013
More Decks by Jason Orendorff
See All by Jason Orendorff
Aristotle's Topics
jorendorff
0
180
Meltdown & Spectre
jorendorff
0
150
<textarea distributed>: An illustrated intro to CRDTs
jorendorff
0
120
Cabbages, Goat, and Wolf In Two Styles!!
jorendorff
0
110
John Wark — Design Principles for a High School Coding Curriculum
jorendorff
1
160
Teaching Programming
jorendorff
2
200
goto fail; — Challenges and Considerations for Teaching Programming to Kids
jorendorff
1
120
How To Fix Bugs
jorendorff
0
160
Compilers 101: An introduction to programming languages and parsing
jorendorff
3
860
Other Decks in Programming
See All in Programming
React Native에 현대적인 빌드 도구 더하기: Rollipop 구현기
leegeunhyeok
0
180
Vue.jsで作る空間解析アプリとCapacitorプラグインのData Bridge
hal_spidernight
1
170
Next.js: The final boss of Web Performance
guaca
0
390
Claude Code ハーネスDeep Dive – 君はどこまで制御する? -
takateeen_knj
6
4.2k
SODA - FACT BOOK(EN)
sodainc
1
220
Seven New Principles of Software Engineering
yegor256
0
470
動画プレイヤーはなぜカクつくのか 〜Flutterのレンダリングとネイティブの境界を解剖する〜
naruogram
0
330
オーケストレーション記述言語 Katari
yukikurage
0
240
複数ドメインを一つのアプリに統合するFlutterの設計と運用_FlutterKaigi2026登壇資料(須永高弘)
takahirosunaga
0
160
Lambda durable functionsでHuman in the Loopを楽に…楽に……
har1101
2
290
小さなアプリを作って公開するまで
onozaty
0
150
Modernizing iOS Apps
seyfoyun
0
150
Featured
See All Featured
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
3
1.4k
Beyond borders and beyond the search box: How to win the global "messy middle" with AI-driven SEO
davidcarrasco
3
300
A brief & incomplete history of UX Design for the World Wide Web: 1989–2019
jct
2
560
We Have a Design System, Now What?
morganepeng
55
8.4k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
35
3.9k
Raft: Consensus for Rubyists
vanstee
143
7.9k
The Cost Of JavaScript in 2023
addyosmani
56
10k
SEO in 2025: How to Prepare for the Future of Search
ipullrank
3
3.9k
Game over? The fight for quality and originality in the time of robots
wayneb77
1
330
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
エンジニアに許された特別な時間の終わり
watany
109
250k
Are puppies a ranking factor?
jonoalderson
2
4.2k
Transcript
Functional Reactive Programming
“Everything flows, nothing stands still.” Heraclitus
Streams of Events
Streams of Events • Fire and forget events are relatively
easy to create.
Streams of Events • Fire and forget events are relatively
easy to create. • UIs
Streams of Events • Fire and forget events are relatively
easy to create. • UIs • Ajax posts
Streams of Events • Fire and forget events are relatively
easy to create. • UIs • Ajax posts • Messaging queues
Processing Events
Processing Events • A little trickier
Processing Events • A little trickier • difficult to compose
Processing Events • A little trickier • difficult to compose
• lots of plumbing
Processing Events • A little trickier • difficult to compose
• lots of plumbing • Callback Hell
“We’re going to need a bigger boat.”
FRP • A model for values that vary over time
• Originates from Haskell Community • Several different implementation styles • We are focusing on Microsoft’s ReactiveExtenions style
Observable
Observable • A marriage of Iterables and the Observer Pattern
Observable • A marriage of Iterables and the Observer Pattern
• Typical Sequence functions - Map, Filter, Reduce, Take
Observable • A marriage of Iterables and the Observer Pattern
• Typical Sequence functions - Map, Filter, Reduce, Take • Subscribe/OnNext
Observable • A marriage of Iterables and the Observer Pattern
• Typical Sequence functions - Map, Filter, Reduce, Take • Subscribe/OnNext • Error Handling
Observable • A marriage of Iterables and the Observer Pattern
• Typical Sequence functions - Map, Filter, Reduce, Take • Subscribe/OnNext • Error Handling • Timing function - Delay
Observable • A marriage of Iterables and the Observer Pattern
• Typical Sequence functions - Map, Filter, Reduce, Take • Subscribe/OnNext • Error Handling • Timing function - Delay • Buffering - Last N events
Observable • A marriage of Iterables and the Observer Pattern
• Typical Sequence functions - Map, Filter, Reduce, Take • Subscribe/OnNext • Error Handling • Timing function - Delay • Buffering - Last N events • Composable - SelectMany/FlatMap
Marble Diagrams
A Marble Diagrams
A Marble Diagrams
A B Marble Diagrams
A B Marble Diagrams
A B A.merge(B Marble Diagrams
A B A.merge(B Marble Diagrams
A B A.merge(B Marble Diagrams
A B A.merge(B Marble Diagrams
A B A.merge(B Marble Diagrams
A B A.merge(B Marble Diagrams
A B A.merge(B Marble Diagrams
A B A.merge(B Marble Diagrams
A B A.merge(B Marble Diagrams
A B A.merge(B Marble Diagrams
A B A.merge(B Marble Diagrams
Autocomplete • On Keyup • Get the value of the
field • Only values of length 3 or more • Make remote call • Filter out bad response • Display results
Autocomplete in reality • On Keyup • Get the value
of the field • Throttle to 500ms • Only values of length 3 or more • Skip duplicates • Make remote call • Filter out bad response • Display results
Demo Source code: https://github.com/Cicayda/yolk-examples