Structure your GraphQL apps!
summary
Proposes structuring Flutter GraphQL apps by co‑locating fragments with widgets and using build_runner + graphql codegen to emit generated serializers per selection set and client extensions. Fragments let one composite query replace the waterfall of child queries so the UI issues a single network request replacing waterfall while each widget depends only on its fragment. Generator creates hooks like the useQuery$fetchMovies hook, gives null‑safe models, fewer runtime errors, and a Relay‑inspired graphql_switch client in early development.
AI-written summary · about
chapters (9)
- 0:00Introduction and goals
- 1:58GraphQL basics
- 4:27Comparing GraphQL and REST
- 7:38Overcoming GraphQL pitfalls
- 11:03Component-based architecture
- 14:26Using fragments
- 17:58Code generation in Dart
- 22:04The code gen framework
- 27:29Future and community
related talks
20mColocating & Composing Data Dependencies with Fragments
23mGraphQL in real life
27mStranger Graphs - Building Federated Workflows with Shared Components
59mBuilding Distributed GraphQL APIs
50mDistributed GraphQL APIs: Breaking Down Monoliths & Unlocking Agility for Dev Teams
50mDistributed Architectures for Distributed Teams
15mThe Evolution of GraphQL Code Generation
16mIntro to GraphQL
