$30 off During Our Annual Pro Sale. View Details »
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Visual Intro to Custom React Hooks
Search
Inky Collective
July 16, 2019
Technology
0
2.6k
Visual Intro to Custom React Hooks
Lightning talk @ Reactadelphia July 2019! melody.dev/custom-hooks
Inky Collective
July 16, 2019
Tweet
Share
More Decks by Inky Collective
See All by Inky Collective
Glowing Up... with Ponies!
pixely
0
63
lo-fi hip hop beats to npm install to!
pixely
0
2.9k
Web Development w/ IE6 (like it’s 2018!)
pixely
0
1.8k
Spooking Your Friends with Electron (BrooklynJS #59)
pixely
0
3.4k
Rebble.io by Peach Hack (#PonyDev @ BronyCon 2018)
pixely
0
170
Sweetie Bot, Part 3 by Cloud Hop (#PonyDev @ BronyCon 2018)
pixely
0
89
Pony Podcast Programming by Corpulent Brony (#PonyDev @ BronyCon 2018)
pixely
1
100
How Equestria Was Made: Building EFNW's Website by Pixely (Everfree Northwest 2018)
pixely
0
430
IRC: Why it Failed by Cadey (#PonyDev @ Everfree Northwest 2018)
pixely
0
98
Other Decks in Technology
See All in Technology
GitHub Copilotを使いこなす 実例に学ぶAIコーディング活用術
74th
3
1.7k
20251209_WAKECareer_生成AIを活用した設計・開発プロセス
syobochim
5
1.4k
【AWS re:Invent 2025速報】AIビルダー向けアップデートをまとめて解説!
minorun365
4
480
Uncertainty in the LLM era - Science, more than scale
gaelvaroquaux
0
810
Kiro Autonomous AgentとKiro Powers の紹介 / kiro-autonomous-agent-and-powers
tomoki10
0
320
世界最速級 memcached 互換サーバー作った
yasukata
0
330
AWS Trainium3 をちょっと身近に感じたい
bigmuramura
1
130
Challenging Hardware Contests with Zephyr and Lessons Learned
iotengineer22
0
130
【CEDEC+KYUSHU2025】学生・若手必見!テクニカルアーティスト 大全 ~仕事・スキル・キャリアパス、TAの「わからない」を徹底解剖~
cygames
PRO
0
150
乗りこなせAI駆動開発の波
eltociear
1
1k
品質のための共通認識
kakehashi
PRO
3
220
Oracle Technology Night #95 GoldenGate 26ai の実装に迫る1
oracle4engineer
PRO
0
150
Featured
See All Featured
Stop Working from a Prison Cell
hatefulcrawdad
273
21k
Fireside Chat
paigeccino
41
3.7k
Building an army of robots
kneath
306
46k
Navigating Team Friction
lara
191
16k
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.5k
How to train your dragon (web standard)
notwaldorf
97
6.4k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
1.1k
Building Flexible Design Systems
yeseniaperezcruz
330
39k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.6k
Bootstrapping a Software Product
garrettdimon
PRO
307
120k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
55
3.1k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
162
15k
Transcript
Custom React Hooks! by Melody, 1x engineer ✨ Reactadelphia July
2019
hey hi, i’m melody! they/them { , , , }
melody.dev
Let’s talk hooks. “They let you use state and other
React features without writing a class.” —Dan Abramov
Say you have a blog:
Where can custom hooks be used? “where is stateful logic
involved?” “can this logic be reused?”
Where can custom hooks be used? <NavItem> <ReadIndicator> <ToggleTheme>
Where can custom hooks be used? history user preferences
Let’s make a hook! psst… they’re just functions! • it
has to start with `use` • you can use other hooks in them • notably, useState() and other custom hooks!
Hooks in action: useHistory() <NavItem> <ReadIndicator>
Hooks on the net! usehooks.com
useDarkMode() usehooks.com/useDarkMode
Hooks in action: useHistory() <NavItem> <ReadIndicator> useDarkMode() <Application> <ToggleTheme>
Hooks in action: useHistory() <NavItem> <ReadIndicator> useDarkMode() <Application> <ToggleTheme>
useYourImagination() Here are some helpful resources: • https://reactjs.org/docs/hooks-custom.html • https://usehooks.com
useThankYou() @pixelyunicorn @melody melody.dev/custom-hooks patreon.com/madebymelody SW-4207-5422-1528