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
74
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
35
Introdução ao GraphQL
paulohp
0
41
Side Effects: Uma Saga até o React
paulohp
0
79
MobX: State Management made easy
paulohp
0
81
Docker: The Rise of Containers
paulohp
0
85
We Work Remotely
paulohp
2
89
Angular2
paulohp
0
220
Node.js Codelab
paulohp
1
170
NodeBR, um ano memoravel!
paulohp
0
88
Other Decks in Programming
See All in Programming
Ruby on cygwin 2025-02
fd0
0
150
苦しいTiDBへの移行を乗り越えて快適な運用を目指す
leveragestech
0
640
Open source software: how to live long and go far
gaelvaroquaux
0
640
Software Architecture
hschwentner
6
2.1k
Amazon Q Developer Proで効率化するAPI開発入門
seike460
PRO
0
110
Java Webフレームワークの現状 / java web framework at burikaigi
kishida
9
2.2k
SwiftUIで単方向アーキテクチャを導入して得られた成果
takuyaosawa
0
270
GAEログのコスト削減
mot_techtalk
0
120
PHPカンファレンス名古屋2025 タスク分解の試行錯誤〜レビュー負荷を下げるために〜
soichi
1
210
XStateを用いた堅牢なReact Components設計~複雑なClient Stateをシンプルに~ @React Tokyo ミートアップ #2
kfurusho
1
910
Serverless Rust: Your Low-Risk Entry Point to Rust in Production (and the benefits are huge)
lmammino
1
110
Amazon ECS とマイクロサービスから考えるシステム構成
hiyanger
2
570
Featured
See All Featured
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
29
1k
Side Projects
sachag
452
42k
Faster Mobile Websites
deanohume
306
31k
Mobile First: as difficult as doing things right
swwweet
223
9.3k
Done Done
chrislema
182
16k
[RailsConf 2023] Rails as a piece of cake
palkan
53
5.2k
StorybookのUI Testing Handbookを読んだ
zakiyama
28
5.5k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
12
960
Producing Creativity
orderedlist
PRO
344
39k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
4
410
The Art of Programming - Codeland 2020
erikaheidi
53
13k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
4
330
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