GraphQL by Example

GraphQL by Example

English | MP4 | AVC 1280×720 | AAC 44KHz 2ch | 67 lectures (5h 39m) | 2.00 GB

Learn GraphQL by writing full-stack JavaScript applications with Node.js, Express, Apollo Server, React, Apollo Client.

More and more teams are choosing GraphQL instead of (or along with) REST for their web APIs. GraphQL queries give clients great flexibility in the way they request data from the server, preventing issues such overfetching or underfetching of data, and allowing multiple resources to be retrieved in a single request.

In this course you’ll learn how to use GraphQL both on the server side and in client applications through practical examples in the form of full-stack JavaScript applications. You will be introduced to all the main GraphQL concepts like schema definition, Queries, Mutations, and Subscriptions, as well as to solution to common requirements such as handling authentication/authorization and client-side caching.

The examples use Apollo Server with Node.js and Express on the backend and React on the frontend, with GraphQL-Request first, then Apollo Client as GraphQL clients. GraphQL-WS is used for subscriptions.

The aim however is not just to cover specific GraphQL libraries, but to give you a more general understanding of the underlying concepts. For instance, GraphQL client libraries are introduced only after learning how to write a simple client “by hand”, to make sure you understand the GraphQL over HTTP format.

This course assumes good knowledge of modern JavaScript, and ideally some familiarity with Node.js/Express and React.

What you’ll learn

  • Build a GraphQL server based on NodeJS, Express and Apollo Server
  • Invoke GraphQL APIs from JavaScript client applications using regular HTTP requests or Apollo Client
  • Handle Authentication/Authorization, Caching, and more
Table of Contents

Introduction
1 What is GraphQL
2 PreRequisites

Fundamentals
3 Schema Definition Language
4 Resolver Functions
5 Query Language
6 GraphQL over HTTP
7 GraphQL Client
8 Source Code

Queries
9 Job Board Project
10 Apollo Server for Express
11 Source Code
12 Custom Type Definition
13 Database Resolver
14 Field Selection
15 JobCompany Association
16 GraphQLRequest Client
17 React Data Fetching
18 Query Arguments
19 Query Variables
20 Exercise Company Query
21 CompanyJobs Association
22 Object Graph Navigation
23 Error Handling

Mutations
24 Mutation Definition
25 Input Types
26 Mutation Request
27 Exercise deleteJob Mutation
28 Exercise updateJob Mutation

Authentication
29 Authentication Flow
30 Resolver Context
31 UserCompany Association
32 Request Authentication
33 Exercise Secure UpdateDelete

Apollo Client
34 Apollo Client Features
35 Apollo Client Installation
36 Query Method
37 Query Method Variables
38 Mutate Method
39 Apollo Client Cache
40 Fetch Policy
41 Cache Manipulation
42 Fragments

Apollo React Hooks
43 useQuery Hook
44 Custom Hooks
45 useQuery with Variables
46 Exercise useCompany
47 useMutation Hook
48 useMutation Result
49 Exercise useCreateJob

Data Loaders
50 SQL Database
51 N1 Query Problem
52 DataLoader
53 PerRequest Cache

Subscriptions
54 Chat Project
55 Source Code
56 Cache updateQuery
57 Subscription Definition
58 GraphQLWS Server
59 Subscription Resolver
60 GraphQLWS Client
61 useSubscription Hook
62 WebSocket Protocol
63 Connection Params
64 WebSocket Server Auth

Update Apollo Server 4
65 Apollo Server 4 Overview
66 Express Project Upgrade

Conclusion
67 Congratulations and Bonus

Homepage