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
GraphQL 101
Search
Paulo Pires
November 30, 2017
Programming
0
83
GraphQL 101
Paulo Pires
November 30, 2017
Tweet
Share
More Decks by Paulo Pires
See All by Paulo Pires
Introdução ao WebAssembly
paulohp
0
43
Introdução ao GraphQL
paulohp
0
46
Side Effects: Uma Saga até o React
paulohp
0
82
MobX: State Management made easy
paulohp
0
86
Docker: The Rise of Containers
paulohp
0
90
We Work Remotely
paulohp
2
96
Angular2
paulohp
0
230
Node.js Codelab
paulohp
1
170
NodeBR, um ano memoravel!
paulohp
0
95
Other Decks in Programming
See All in Programming
STUNMESH-go: Wireguard NAT穿隧工具的源起與介紹
tjjh89017
0
290
新世界の理解
koriym
0
130
대규모 트래픽을 처리하는 프론트 개발자의 전략
maryang
0
120
Constant integer division faster than compiler-generated code
herumi
2
560
0から始めるモジュラーモノリス-クリーンなモノリスを目指して
sushi0120
0
250
技術的負債で信頼性が限界だったWordPress運用をShifterで完全復活させた話
rvirus0817
0
840
JetBrainsのAI機能の紹介 #jjug
yusuke
0
190
実践 Dev Containers × Claude Code
touyu
1
160
Dart 参戦!!静的型付き言語界の隠れた実力者
kno3a87
0
180
What's new in Adaptive Android development
fornewid
0
140
バイブスあるコーディングで ~PHP~ 便利ツールをつくるプラクティス
uzulla
1
330
書き捨てではなく継続開発可能なコードをAIコーディングエージェントで書くために意識していること
shuyakinjo
0
240
Featured
See All Featured
Stop Working from a Prison Cell
hatefulcrawdad
271
21k
Imperfection Machines: The Place of Print at Facebook
scottboms
267
13k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
3.9k
How to train your dragon (web standard)
notwaldorf
96
6.2k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
7
800
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
RailsConf 2023
tenderlove
30
1.2k
The Cult of Friendly URLs
andyhume
79
6.5k
Learning to Love Humans: Emotional Interface Design
aarron
273
40k
Faster Mobile Websites
deanohume
308
31k
Gamification - CAS2011
davidbonilla
81
5.4k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
29
1.8k
Transcript
GraphQL 101 @caofrade
Objetivo
GraphQL Novo padrão para APIs Linguagem de Query (consulta) Open-source
mantido pela galera do Facebook
Quem usa?
MUITO, MAS MUITO CONTEUDO
HYPE? Que problema o GraphQL resolve mesmo?
REST
REST •Representational State Transfer •Arquitetura baseada em recursos: - Entidades
do sistema - Identificados por URIs - Manipulado por representações (JSON, XML, HTML)
None
None
Problemas •Overfetching - Download de dados desnecessários. •Underfetching - Acessar
mais de 1 endpoint para juntar os dados necessários.
GraphQL
Conceitos
Schema •Recursos são definidos por um sistema de tipos •Contrato
entre cliente e servidor sobre como a aplicação pode acessar os dados. •Schema Definition Language (SDL)
None
Query •No REST, múltiplos endpoints retornam estruturas de dados fixas.
•Em GraphQL, existe um único endpoint, onde o cliente determina qual dado é necessário.
None
None
None
None
Mutation •Responsável por criar e mudar dados armazenados no back-end.
None
None
Schema •Query e Mutation também precisam ser definidos no Schema
•São os pontos de entrada para as requisições enviadas pelo cliente.
None
Como Usar?
facebook.github.io/relay
apollographql.com/client
GraphQL não é magica!
E não vai matar o REST!
Obrigado @caofrade