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
Getting Started with GraphQL
Search
Shodipo Ayomide
May 04, 2019
Programming
260
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Getting Started with GraphQL
Getting Started with GraphQL talk at Full Stack Developers Conference Lagos.
Shodipo Ayomide
May 04, 2019
More Decks by Shodipo Ayomide
See All by Shodipo Ayomide
SINFO Keynote - Technical Principles of Developer Experience (DX)
developerayo
0
58
MautiCon - The Ideal Community Model: Lessons Learned
developerayo
0
77
Global Accessibility: The Future is Open - unStack Keynote
developerayo
0
67
Fast and Furious with VueJS & WebPack
developerayo
0
110
Automate Workflow processes using GitHub Actions
developerayo
0
130
Building A React App With Web And Mobile In Mind
developerayo
1
100
Design From The Realm of Open-Source
developerayo
0
67
Design From The Dimension of Open-Source - Shodipo Ayomide - React Finland
developerayo
0
88
Optimizing for Super Sonic Speed in Vue.js & Gridsome
developerayo
0
340
Other Decks in Programming
See All in Programming
Claude CodeとAgentCore Gatewayを繋ぐ際の認証認可 / Authentication and authorization when connecting Claude Code with AgentCore Gateway
har1101
0
140
仕様書を書く前にハーネスを作る - Agent Native開発は「探索を速く、判定を固く」
gotalab555
4
1.5k
なぜ関数型プログラミングで「型」と「証明」が語られるのか #fp_matsuri
kajitack
3
1.1k
Go言語とトイモデルで学ぶTransformerの気持ち / fukuokago23-transformer
monochromegane
0
160
今さら聞けない .NET CLI
htkym
0
180
2年かけて Deno に DOMMatrix を実装した話 / How I implemented DOMMatrix in Deno over two years
petamoriken
0
200
仕様駆動開発の消費期限
watany
6
980
AI時代のPHPer生存戦略 ~「言語、もうなんでもよくない?」に本気で向き合う~
vivion
0
230
テーブルをDELETEした
yuzneri
0
130
Laravel Boostに学ぶ、AIにPHPを書かせる技術 〜OSSの実装から蒸留するエージェント制御の王道〜
kentaroutakeda
3
650
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
510
【やさしく解説 設計編・中級 #6】良いアーキテクチャとは ~ 一本の登り道の、行き先 ~
panda728
PRO
0
200
Featured
See All Featured
Automating Front-end Workflow
addyosmani
1370
210k
Organizational Design Perspectives: An Ontology of Organizational Design Elements
kimpetersen
PRO
1
790
Leading Effective Engineering Teams in the AI Era
addyosmani
9
2.2k
The Cost Of JavaScript in 2023
addyosmani
55
10k
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
0
560
Money Talks: Using Revenue to Get Sh*t Done
nikkihalliwell
0
450
The Spectacular Lies of Maps
axbom
PRO
1
890
Agile Actions for Facilitating Distributed Teams - ADO2019
mkilby
0
240
HU Berlin: Industrial-Strength Natural Language Processing with spaCy and Prodigy
inesmontani
PRO
0
600
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
23k
Making the Leap to Tech Lead
cromwellryan
135
10k
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
680
Transcript
Shodipo Ayomide (@developerayo) | Full Stack Developers Conference)
Hello! 2
What is GraphQL 3
4 GraphQL is a syntax that describes how to ask
for data, and is generally used to load data from a server to a client. In other words
5 GraphQL is a query language for your API
6
7 JavaScript Typescript Ruby PHP Python Java C/C++ Perl .NET
Erlang Elixar Haskel Rust Lua Scala Clojure ClojureScript Swift OCaml SQL R Elm GraphQL supports a whole lot of languages and frameworks
8 GraphQL supports a whole lot of languages and frameworks
Kotlin GO Crystal
Companies using GraphQL 9 http://blog.honeypot.io/assets/images/ql-companies.png
Let that sink in! 10 REST APIs returns resources you
do not need, that’s why you have a bunch of endpoint’s you do not need
11
12 GraphQL To The Rescue
Ask for what you need, and get exactly that. NO
EXTRAS 13 Send a GraphQL query to your API and get exactly what you need, nothing more and nothing less. Apps using GraphQL are fast and stable because they control the data they get, not the server.
14 { viewer { name email } } Example
15 { viewer { name email } } Example
16 { "data": { "viewer": { "name": "Shodipo Ayomide", "email":
"
[email protected]
" } } } { viewer { name email } } POST: https://api.github.com/graphql
17 { user(login: "developerayo") { name location repositories { name
} } } Example
18 { user(login: "developerayo") { name location repositories { name
} } } POST: https://api.github.com/graphql { "data": { "user": { "name": “Shodipo Ayomide", "location": “Lagos, Nigeria", "repositories": [ { "name": “awesome-nuxtjs" }, { "name": “react-notify" }, { "name": “shodipoayomide.com" }, ... } } }
Versioning made easy 19 Add new fields and types to
your GraphQL API without impacting existing queries “think GitHub PR”. encourage cleaner, more maintainable server code.
20 GET /GraphQL Request Body Response Body query { post(id:
1) { id title tagline votesCount commentsCount thumbnailUrl hunter: { id avatarUrl } } }
21 GET /GraphQL Request Body Response Body query { post(id:
1) { id title tagline votesCount commentsCount thumbnailUrl hunter: { id avatarUrl } } }
22 GET /GraphQL Request Body Response Body query { post(id:
1) { id title tagline votesCount commentsCount thumbnailUrl hunter: { id avatarUrl } } } { "data": { "post": { "id": 1, "title": "Developerayo’s Blog", "tagline": "Articles on Soft.", "votesCount": 490, "commentsCount": 7,648, "thumbnailUrl": "google.com/tbn" "hunter": { "id": 1, "avatarUrl": "google.com/tbn" } } } }
23 A little Workshop Open CodeSandBox
The Apollo GraphQL platform is an implementation of GraphQL that
helps you manage data from the cloud to your UI. Got any questions about apollo? speak to @unicodeveloper https://www.apollographql.com
None
None
None
There is no Limit to what you can build 28
GraphQL Tools 29
GraphQL CSS 30 graphql-css is a blazing fast CSS-in-GQL library
that converts GraphQL queries into styles for your components https://github.com/braposo/graphql-css
GraphiQL 31 An interactive in-browser GraphQL IDE tool for GraphQL
https://github.com/graphql/graphiql
Graphcool 32 Self-Hosted GraphQL BaaS (Backend as a Service) https://www.graph.cool/
a GraphQL backend for your applications with a powerful web ui for managing your database and stored data
READY TO LEARN GRAPHQL? 33
Resources 34 GraphQL: https://graphql.org Apollo graphql: https://apollographql.com GraphiQL: https://github.com/graphql/graphiql Let’s
Learn GraphQL by Sara Vieira https://letslearngraphql.com/ How to GraphQL: https://howtographql.com GraphQL CSS https://github.com/braposo/graphql-css
35
Thanks! Any questions? You can find me @developerayo on Twitter,
GitHub, Everywhere Read some blog post here https://shodipoayomide.com 36