Skip to content

Blog

One subject per article, each with a runnable demo and a video.

Custom GraphQL Queries in Dart: Select Only the Fields You Need

GraphQL promises that you can ask for exactly what you want and no more. In the last video the generated client fetched every book together with its author. That is fine until you only need the books.

This post covers the next step: write your own query, let GraphLink generate the method for it, and see what the generated Dart looks like. The video shows all of it, and the sections below follow the same order.

Generate a Typed GraphQL Client for Dart in One Command

A GraphQL schema is fully typed. Then you write the Dart client by hand, and the types stop at the network boundary: Map<String, dynamic>, string keys, casts, and a query string you hope matches the server.

GraphLink skips that part. It reads your schema and writes the client for you, with models, inputs, queries and mutations, all typed and null-safe. This post is the quickstart: one schema, one command, and a first query against a real server. The video shows all of it, and the sections below follow the same order.

The Pains of GraphQL Clients, and How to Remove Them

GraphQL is a good deal on paper. You get a typed schema, one endpoint, and clients that ask for exactly the data they need. Then you write the client, and the typed schema stops at the network boundary.

This post walks through the six pains I kept running into when building GraphQL clients, and what happens to each of them when the client code is generated from the schema instead of written by hand. Each section links to a short video that shows it in action.