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
React-Haskell
Search
Joel Burget
November 19, 2014
Programming
3
420
React-Haskell
Khan Academy dev standup presentation.
https://github.com/joelburget/react-haskell
Joel Burget
November 19, 2014
Tweet
Share
More Decks by Joel Burget
See All by Joel Burget
Backbone to React
joelburget
24
67k
Other Decks in Programming
See All in Programming
Navigating Dependency Injection with Metro
l2hyunwoo
1
190
Developing static sites with Ruby
okuramasafumi
0
330
実は歴史的なアップデートだと思う AWS Interconnect - multicloud
maroon1st
0
270
Rubyで鍛える仕組み化プロヂュース力
muryoimpl
0
210
Findy AI+の開発、運用におけるMCP活用事例
starfish719
0
1.8k
0→1 フロントエンド開発 Tips🚀 #レバテックMeetup
bengo4com
0
410
Canon EOS R50 V と R5 Mark II 購入でみえてきた最近のデジイチ VR180 事情、そして VR180 静止画に活路を見出すまで
karad
0
140
TerraformとStrands AgentsでAmazon Bedrock AgentCoreのSSO認証付きエージェントを量産しよう!
neruneruo
4
1.9k
これならできる!個人開発のすゝめ
tinykitten
PRO
0
130
「コードは上から下へ読むのが一番」と思った時に、思い出してほしい話
panda728
PRO
39
26k
C-Shared Buildで突破するAI Agent バックテストの壁
po3rin
0
420
The Art of Re-Architecture - Droidcon India 2025
siddroid
0
140
Featured
See All Featured
Neural Spatial Audio Processing for Sound Field Analysis and Control
skoyamalab
0
130
Ethics towards AI in product and experience design
skipperchong
1
140
Digital Ethics as a Driver of Design Innovation
axbom
PRO
0
130
Technical Leadership for Architectural Decision Making
baasie
0
190
Abbi's Birthday
coloredviolet
0
3.9k
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
110
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
122
21k
Mind Mapping
helmedeiros
PRO
0
40
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
48
[RailsConf 2023] Rails as a piece of cake
palkan
58
6.2k
Tell your own story through comics
letsgokoyo
0
770
Building an army of robots
kneath
306
46k
Transcript
None
REACT-HASKELL
HI, MY NAME IS JOEL
HI, MY NAME IS JOEL ... AND I USE HASKELL
HASKELL ▸ statically typed ▸ lazy ▸ purely functional
HASKELL ▸ statically typed ▸ lazy ▸ purely functional ▸
really cool
HASTE ▸ dialect of Haskell ▸ runs in browser
HASTE
BLAZE-HTML sample :: Html sample = p ! class_ "styled"
$ em "Basic Algebra" becomes <p class="styled"> <em>Basic Algebra</em> </p>
REACT-HASKELL sample :: React sample = p <! className "styled"
$ em "Basic Algebra" becomes <p class="styled"> <em>Basic Algebra</em> </p>
PUT IT ON THE PAGE main :: IO () main
= do Just elem <- elemById "id" render elem sample
MORE COMPLICATED sample :: React sample = div <! className
"beautify" $ do "Khan Academy" input "Rewritten in Haskell"
CONTROLLED COMPONENT view :: Elem -> JSString -> IO ()
view elem str = render elem $ div $ do "Khan Academy" input <! onChange (view elem . targetValue) text str
None
LET'S MAKE THAT EASIER
STATEFUL COMPONENT REDUX view :: StatefulReact JSString view = div
$ do "Khan Academy" input <! onChange' (updateState . targetValue) text str
LIFECYCLE METHODS componentDidMount, componentWillUnmount, ... ?
QUESTIONS?