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
Lightning Talk at JSConf 2015
Search
Dafeng
July 12, 2015
Programming
12
1.3k
Lightning Talk at JSConf 2015
Quick intro to GraphQL and Relay
Dafeng
July 12, 2015
Tweet
Share
More Decks by Dafeng
See All by Dafeng
Things to Know before Building Large-scale React.js Application
dfguo
6
1.9k
ReactJS in Strikingly
dfguo
6
1.1k
I’ ve shipped the code, what’ s next
dfguo
6
620
Other Decks in Programming
See All in Programming
Amazon Bedrock Agentsを用いてアプリ開発してみた!
har1101
0
320
Hotwire or React? ~アフタートーク・本編に含めなかった話~ / Hotwire or React? after talk
harunatsujita
1
120
AWS Lambdaから始まった Serverlessの「熱」とキャリアパス / It started with AWS Lambda Serverless “fever” and career path
seike460
PRO
1
240
Pinia Colada が実現するスマートな非同期処理
naokihaba
4
220
とにかくAWS GameDay!AWSは世界の共通言語! / Anyway, AWS GameDay! AWS is the world's lingua franca!
seike460
PRO
1
820
What’s New in Compose Multiplatform - A Live Tour (droidcon London 2024)
zsmb
1
470
「今のプロジェクトいろいろ大変なんですよ、app/services とかもあって……」/After Kaigi on Rails 2024 LT Night
junk0612
5
2.1k
弊社の「意識チョット低いアーキテクチャ」10選
texmeijin
5
24k
ローコードSaaSのUXを向上させるためのTypeScript
taro28
1
530
Snowflake x dbtで作るセキュアでアジャイルなデータ基盤
tsoshiro
2
510
C++でシェーダを書く
fadis
6
4.1k
Importmapを使ったJavaScriptの 読み込みとブラウザアドオンの影響
swamp09
4
1.4k
Featured
See All Featured
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
42
9.2k
10 Git Anti Patterns You Should be Aware of
lemiorhan
654
59k
RailsConf 2023
tenderlove
29
900
The Illustrated Children's Guide to Kubernetes
chrisshort
48
48k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
93
16k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
506
140k
Fireside Chat
paigeccino
33
3k
Optimizing for Happiness
mojombo
376
70k
VelocityConf: Rendering Performance Case Studies
addyosmani
325
24k
Music & Morning Musume
bryan
46
6.2k
Ruby is Unlike a Banana
tanoku
96
11k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
232
17k
Transcript
GraphQL and Relay Lightning Talk at JSConf 2015
About me • Dafeng Guo, CTO of strikingly.com • Strikingly
• simplest website builder • probably the largest React.js user in China
GraphQL What the hell is it?
None
None
“REST is perfect!” - A random backend engineer
REST-ful API Sometimes Sucks • Round trip for complicated objects
• Variable fields • Custom endpoint - not REST-ful design • Backend engineer dependency - slow down iterations
GraphQL • Server-side engineers published a type system • Client-side
engineers use GraphQL as a unified query interface • No more adhoc endpoints • Product changes are faster
None
Are we writing SQL in the client?! NO!
GraphQL Query JSON Response
GraphQL • REST-ful sometimes sucks • GraphQL is declarative •
GraphQL allows product engineers to iterate faster • Draft spec was released
Relay GraphQL on React
Component • Component is at the core of React •
Reusing any component, we are reusing • HTML - React • Javascript - React • CSS - Maybe React? • Data fetching - Relay
Relay • Allows you to define the data format the
component needs using GraphQL • Relay automatically fetch the data • Supports nested/composite components
Relay • Solving the data fetching problem • Supports composite
components • Makes component reuse possible • Will be open sourced in August
Thanks!