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
Decoupling UI components for better reusability...
Search
LINE Developers Thailand
October 25, 2024
Technology
0
28
Decoupling UI components for better reusability and test with Storybook
Decoupling UI components for better reusability and test with Storybook
LINE Developers Thailand
October 25, 2024
Tweet
Share
More Decks by LINE Developers Thailand
See All by LINE Developers Thailand
Welcome & Tech Vision Keynote
linedevth
0
92
Building the Future: LINE API Updates in 2024
linedevth
0
68
Revolutionizing Telepharmacy with The POWER of Gen AI and LINE API
linedevth
0
93
Seamless Inventory Management with ChatGPT and LINE SHOPPING API
linedevth
0
43
The Future of LINE Retail Chatbot using Gemini AI
linedevth
0
83
Domain Data Platform for Scalable Data Management
linedevth
0
44
Building a Fortune Teller App with OpenAI From Chatbot to Voice Assistant
linedevth
0
37
B.A.A.S - BeTask AI and Automation for SMEs
linedevth
0
36
Boosting Development Quality through Continuous Documentation Integration
linedevth
0
46
Other Decks in Technology
See All in Technology
日経電子版のStoreKit2フルリニューアル
shimastripe
1
140
ExaDB-D dbaascli で出来ること
oracle4engineer
PRO
0
3.9k
初心者向けAWS Securityの勉強会mini Security-JAWSを9ヶ月ぐらい実施してきての近況
cmusudakeisuke
0
130
Taming you application's environments
salaboy
0
190
rootlessコンテナのすゝめ - 研究室サーバーでもできる安全なコンテナ管理
kitsuya0828
3
390
New Relicを活用したSREの最初のステップ / NRUG OKINAWA VOL.3
isaoshimizu
3
620
iOSチームとAndroidチームでブランチ運用が違ったので整理してます
sansantech
PRO
0
150
iOS/Androidで同じUI体験をネ イティブで作成する際に気をつ けたい落とし穴
fumiyasac0921
1
110
Zennのパフォーマンスモニタリングでやっていること
ryosukeigarashi
0
150
AWS Lambda のトラブルシュートをしていて思うこと
kazzpapa3
2
180
Evangelismo técnico: ¿qué, cómo y por qué?
trishagee
0
360
OCI Security サービス 概要
oracle4engineer
PRO
0
6.5k
Featured
See All Featured
Ruby is Unlike a Banana
tanoku
97
11k
Into the Great Unknown - MozCon
thekraken
32
1.5k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
44
2.2k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
The Art of Programming - Codeland 2020
erikaheidi
52
13k
The Power of CSS Pseudo Elements
geoffreycrofte
73
5.3k
Optimizing for Happiness
mojombo
376
70k
How STYLIGHT went responsive
nonsquared
95
5.2k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
356
29k
Documentation Writing (for coders)
carmenintech
65
4.4k
Testing 201, or: Great Expectations
jmmastey
38
7.1k
What's in a price? How to price your products and services
michaelherold
243
12k
Transcript
Decoupling UI components for better reusability and test with Storybook
Frontend world
UI Frameworks
TEST
• Component segmentation for reusability • Problems we encounter when
implementing a new component • The solution that we test a new component by storybook Agenda
• Action by click or typing • Integrate API •
Integrate stores What do we do on the page
• Handle action event • Call API • Manage data
from API • Re-render view when data changed Spaghetti man Button Button Button Contents Button
Component segmentation for reusability
Input Type 1 Input Type 2 Input Type 3
None
Panel for 5 Button and Content Button Button Contents Label
Button Button Button • Render component • Action by clicked button Focus • Integrate with API • Mutate data Out of scope
Overview Button Button Contents Panel 1 Button Button Button Panel
3 Button Button Button Panel 2 Button Button Button Button Button Contents Panel 4 Button Button Button Container Container • Listen event from each panel to handle action • Action to call API • Action to stores
Problems we encounter when implementing a new component
Test and review
How do we test > Unit test in each component
> Automation test
Issues we often encounter during reviews
A lot of files changed
None
None
The solution that we test a new component by storybook
None
Storybook
None
Reviewer Create PR
Key takeaways > Making components easily reusable > Storybook helps
reduce the time spent on testing and reviewing > Let’s have fun with the storybook
None