If you’ve been entrusted to build something important, it’s always good to know you have resources to rely on. Maybe a team member. Maybe a book or a course. Walking into a project with a set of new tools can be pretty scary.
That’s where I think best practices come in.
As a part of the Developer Experience team at Apollo, and someone who personally uses Apollo’s tools, I totally know what it feels like to not know if I’m doing things correctly. That’s why I’ve decided to work with the Apollo Client team to help put together the Apollo Client Best Practices series.
Apollo Client is, first and foremost, a GraphQL client library. You can cache subsets of your backend data graph on the client-side and work with it the same way you’d work with
global state using tools like Redux or React Context. This means Apollo Client is also a state management library and a data-fetching tool. State management and data fetching are two massive pieces of the puzzle building client-apps, but there are other problems to solve too.
What about architecture? How do we handle the various types of state (component, local, remote)? What about testing, pagination, server-side rendering, or security?
We like principles. This series is a curation of our advice for how to use Apollo Client to build testable, flexible, and maintainable production applications.
Where should I start?
If you’re rusty or unfamiliar with Apollo Client and GraphQL, I’d recommend first walking through the getting started guide, learning about queries and mutations, then trying out the full-stack tutorial.
After that, check out the posts from the series in order.
Here are the current best practices guides.
- Apollo Client & Client-side Architecture Basics
- Local State Management with Reactive Variables
- Demystifying Cache Normalization
- When to Use Refetch Queries in Apollo Client
- Redux to Apollo: Data Access Patterns
Have an idea for another guide you’d like to see? Use the feedback form below to suggest another topic!
Stay in our orbit!
Become an Apollo insider and get first access to new features, best practices, and community events. Oh, and no junk mail. Ever.
Make this article better!
Was this post helpful? Have suggestions? Consider so we can improve it for future readers ✨.