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 - JavaScript Fullstack Solution
Search
Michael Hsu
December 29, 2017
Programming
2
310
GraphQL - JavaScript Fullstack Solution
GitHub:
https://github.com/evenchange4/todomvc-subscriptions
Demo:
https://todomvc-web.now.sh/
Michael Hsu
December 29, 2017
Tweet
Share
More Decks by Michael Hsu
See All by Michael Hsu
Front-End Practice 2019
evenchange4
0
900
Other Decks in Programming
See All in Programming
Kotlin Multiplatform Meetup - Compose Multiplatform 외부 의존성 아키텍처 설계부터 운영까지
wisemuji
0
190
AIによる高速開発をどう制御するか? ガードレール設置で開発速度と品質を両立させたチームの事例
tonkotsuboy_com
7
2k
Grafana:建立系統全知視角的捷徑
blueswen
0
330
Package Management Learnings from Homebrew
mikemcquaid
0
210
HTTPプロトコル正しく理解していますか? 〜かわいい猫と共に学ぼう。ฅ^•ω•^ฅ ニャ〜
hekuchan
2
680
AIフル活用時代だからこそ学んでおきたい働き方の心得
shinoyu
0
130
LLM Observabilityによる 対話型音声AIアプリケーションの安定運用
gekko0114
2
420
MDN Web Docs に日本語翻訳でコントリビュート
ohmori_yusuke
0
640
AI & Enginnering
codelynx
0
110
プロダクトオーナーから見たSOC2 _SOC2ゆるミートアップ#2
kekekenta
0
200
2026年 エンジニアリング自己学習法
yumechi
0
130
開発者から情シスまで - 多様なユーザー層に届けるAPI提供戦略 / Postman API Night Okinawa 2026 Winter
tasshi
0
200
Featured
See All Featured
Primal Persuasion: How to Engage the Brain for Learning That Lasts
tmiket
0
250
Exploring the relationship between traditional SERPs and Gen AI search
raygrieselhuber
PRO
2
3.6k
Java REST API Framework Comparison - PWX 2021
mraible
34
9.1k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
2.3k
[RailsConf 2023] Rails as a piece of cake
palkan
59
6.3k
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.6k
The SEO Collaboration Effect
kristinabergwall1
0
350
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
910
Building the Perfect Custom Keyboard
takai
2
680
How GitHub (no longer) Works
holman
316
140k
Embracing the Ebb and Flow
colly
88
5k
Transcript
GRAPHQL - JAVASCRIPT FULLSTACK SOLUTION 2017.12.29 MICHAEL HSU
AGENDA 1. Recap 2. Server 3. Web
RECAP API GATEWAY - PROXY
RECAP GRAPHQL NATIVE - CONNECT TO DATABASE
DEMO ▸ TodoMVC: CRUD + Realtime ▸ https://todomvc-web.now.sh/
TODOMVC - FULLSTACK . (lerna) !"" packages #"" constants #
Shared constants between client and server. #"" server # GraphQL Server !"" web # Web server
SERVER
HOW TO BUILD A GRAPHQL SERVER? (1/3) GRAPHQL OPERATION ▸
Query: R ▸ Mutation: CUD ▸ Subscription: Realtime (WS, MQTT) ▸ https://todomvc-server.now.sh/
HOW TO BUILD A GRAPHQL SERVER? (2/3) LIBRARIES ‣ 1.
graphql-yoga: express, graphql-tools, graphql- subscriptions, graphiql ‣ 2. knex.js: ORM ‣ 3. Pkg: Binary compiler ‣ 4. Docker: Container
HOW TO BUILD A GRAPHQL SERVER? (3/3) MODULE ▸ 1.
connector: connect to database ▸ 2. models: ORM, database manipulate ▸ 3. typeDefs: GraphQL type ▸ 4. resolver: Logic ▸ https://github.com/evenchange4/todomvc-subscriptions/ blob/master/packages/server/README.md
WEB
HOW TO BUILD A GRAPHQL WEB? (1/2) LIBRARIES ▸ 1.
Next.js: Server-rendered React applications ▸ 2. Apollo-client: GraphQL client ▸ 3. Apollo-link-state: Manage local state (redux)
HOW TO BUILD A GRAPHQL WEB? (2/2) MODULE ▸ 1.
gql: GraphQL type ▸ 2. hoc: React ▸ 3. resolvers: GraphQL for local state (getState, reducer) ▸ https://github.com/evenchange4/todomvc-subscriptions/ blob/master/packages/web/README.md
SERVER & WEB CONCLUSION - SIZE ▸ Server: Linux binary
64MB ▸ Web: bundle size 433KB + 101KB (Code split)
FULLSTACK TODOMVC WITH GRAPHQL SUBSCRIPTIONS https://github.com/evenchange4/todomvc-subscriptions TAKEAWAY