~/talk

How to Use Suspense and GraphQL with Apollo to Build Great User Experiences

Talkat GraphQL Summit 2023 · 2023-10-09..10-13· [react, frontend-architecture]
slides:none on file

Demonstrates migrating an app to Apollo Client 3.8 by replacing useQuery with useSuspenseQuery, removing loading booleans so components treat data like synchronous values, and reorganizing Suspense boundaries to trade off single versus nested paints. Shows a Spotify-clone demo that uses the GraphQL defer directive to stream slow fields, fixes pagination hiding existing items with React 18’s startTransition, and mentions useBackgroundQuery/useReadQuery to avoid waterfalls plus type improvements in TypeScript.

AI-written summary · about

  1. 0:00Introduction to talk
  2. 0:23What we’ll cover today
  3. 1:25Context of Suspense in React
  4. 2:29Traditional Apollo client loading states
  5. 3:34Suspense basics and React example
  6. 4:16How Suspense works under the hood
  7. 6:26Suspense beyond loading states
  8. 6:46Introducing useSuspenseQuery
  9. 7:28Demo app overview
  10. 8:10Current loading UX with useQuery
  11. 9:14Converting to useSuspenseQuery
  12. 10:42First suspense boundary
  13. 11:45Converting remaining components
  14. 13:31Grouping updates with suspense
  15. 14:34Single suspense boundary demo
  16. 15:37Navigation and trade-offs
  17. 16:40Nested suspense boundaries
  18. 17:20Handling fast component loads
  19. 18:23Removing synthetic delays
  20. 19:04Improving with defer directive
  21. 21:55Pagination with useSuspenseQuery
  22. 22:56Fixing pagination UX with transitions
  23. 24:20Recap of key improvements
  24. 25:25Other suspense-enabled hooks
  25. 26:06Future suspense features
  26. 26:49Demo code and resources
  27. 27:11Q&A and feedback
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.