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
Full Stackな型安全を支えるGraphQLのFragment活用
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Anji.T
August 28, 2025
Programming
190
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Full Stackな型安全を支えるGraphQLのFragment活用
Anji.T
August 28, 2025
Other Decks in Programming
See All in Programming
AIは賢い。でも実行環境は? CLIおじさんがAI時代に伝えたいこと ~ CLIおじさんがAI時代に伝えたいこと ~
curekoshimizu
1
250
AGENTS.md Is Not Enough:Build Skills, Don't Download Them
lx_t
0
120
GKE で Pod の見方を変えたら、スケールアウト時の挙動を真に捉えられた話
stkk
0
130
AI Agent時代のリアーキテクチャ戦略と実践
hokaccha
9
4.8k
手動確認はもう限界 〜XCUITestでCustom URL Schemeの遷移を起動種別ごとに自動テストする〜 / Testing Custom URL Schemes with XCUITest
otouto
0
310
LoopHub - ローカルで動く GitHub で、AI と共同開発
jugyo
1
560
WebRTC映像をAirPlayに対応させる挑戦.pdf
monolithic_adam
0
290
そのリトライ、死んだコネクションを使い回していませんか ── GoのHTTPクライアントとHTTP/2を実プロダクト障害から学び直す
myus4a
0
150
Vue Fes Japan 2026 タイムテーブル徹底解説
448jp
1
250
iOSDC Japan 2026 - Swiftで作って学ぼう!データベース自作入門
kaseken
2
170
The Good Stuff, Not the Slop: Engineering High-Quality Android Apps with Modern AI Tooling
danybony
1
260
FreeBSDでZabbixを動かす
kenkino
0
310
Featured
See All Featured
SEO for Brand Visibility & Recognition
aleyda
0
4.7k
Leadership Guide Workshop - DevTernity 2021
reverentgeek
1
370
A better future with KSS
kneath
240
18k
brightonSEO & MeasureFest 2025 - Christian Goodrich - Winning strategies for Black Friday CRO & PPC
cargoodrich
3
850
Build your cross-platform service in a week with App Engine
jlugia
234
19k
Building a Modern Day E-commerce SEO Strategy
aleyda
45
9.2k
Effective software design: The role of men in debugging patriarchy in IT @ Voxxed Days AMS
baasie
1
530
A designer walks into a library…
pauljervisheath
211
25k
Build The Right Thing And Hit Your Dates
maggiecrowley
39
3.4k
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
290
First, design no harm
axbom
PRO
2
1.3k
Color Theory Basics | Prateek | Gurzu
gurzu
1
470
Transcript
Full Stackな型安全を支える GraphQLのFragment活用 田中 杏直 / Tanaka Anji 2025/08/28 TsKaigi
Mashup
氏名:田中 杏直 / Tanaka Anji @anji0114 自己紹介 所属:匠技研工業 / プロダクトエンジニア
None
None
• GraphQLでの開発の流れ • データ取得の課題と Fragment • Full Stackな型安全を支える Fragment 今日お話しすること
GraphQLでの開発の流れ
スキーマの定義
バックエンド実装
GraphQL Codegen
生成されたファイル
データ取得の設計課題と Fragment
どこでデータを取得する?問題
他の設計パターン Repository + Hooks • どこでuseUserを呼ぶか? • 親で呼ぶ?子で呼ぶ?複数の場所で呼んだら 重複する? •
コンポーネント追加のたびに、親の取得内容を 都度調整
他の設計パターン Container/Presentational • どのレベルでContainerを作るか? • ページ単位?セクション単位?コンポーネント単 位?
Fragment Colocationを使用することで
子は親の取得位置を気にせず開発することできる
Full Stackな型安全を支える Fragment
None
バックエンド側で schemaを変更した時
型エラーをコンポーネントレベルで出すことができる
コンポーネントが増えた場合でも
該当コンポーネントだけを変えれば良い
まとめ • 従来の「どこでクエリを呼ぶか?」「親子で重複してない?」という判断コスト が減る。 • 各コンポーネントが必要なデータを Fragmentで宣言するため、 親の設計 や他コンポーネントの実装を知る必要がない。 •
バックエンド側で Schemaを変更時、コンポーネントレベルでコンパイルエ ラーを出してくれる。
匠技研工業ではエンジニアを募集しています!!
ありがとうございました!