Never miss a release that matters
AI-powered summaries of every GitHub release.
AI Summaries
Changelogs condensed into clear, actionable insights.
Always Free
Track up to 5 packages at no cost, forever.
Weekly Digest
A curated summary of every release, delivered weekly.
TL;DR
Apollo Client now correctly updates polling intervals for useLazyQuery and preserves data references during refetches, improving performance and preventing unexpected re-renders.
Fixes Worth Knowing
useLazyQuerynow correctly applies updatedpollIntervalvalues (automatic data refresh).- Referential equality of data is preserved on refetch when data hasn’t changed, optimizing component updates.
TL;DR
Apollo Client now correctly merges refetchOn options, allowing defaults to apply when per-query settings are incomplete, improving control over data refetching behavior.
Fixes Worth Knowing
refetchOnmerging is fixed: default options now apply to unspecified events when configuringwatchQuery.- A deprecation warning for older function signatures (function overloads) has been corrected to only apply to explicitly typed signatures, encouraging use of
TypedDocumentNode(strongly typed queries). - Type safety for
preloadQuery(pre-fetching data) has been improved, ensuring correct data states.
Before You Upgrade
If you’re explicitly setting refetchOn with objects, verify that your desired events are configured; otherwise, your default refetchOn settings will now apply.
TL;DR
Apollo Client now correctly silences deprecation warnings, even when used in different parts of your application, improving console clarity.
Fixes Worth Knowing
Deprecation warnings are now consistently muted when globally disabled, resolving issues where warnings reappeared unexpectedly.
Before You Upgrade
If you globally muted deprecation warnings, verify they remain silenced after upgrading.
TL;DR
Apollo Client’s code generation tooling now requires updating your GraphQL code generation dependencies due to major version bumps.
Breaking
- GraphQL code generation dependencies (tools for generating code) must be updated to the latest major versions.
Before You Upgrade
- Update your GraphQL code generation packages (e.g.,
graphql,graphql-tag) to their latest major versions.
TL;DR
Apollo Client now supports generating resolver types for LocalState (client-side data management) using a new GraphQL Codegen plugin, streamlining type safety for local data.
Breaking
- Codemod Required: A codemod is available to update import paths from Apollo Client v3 to v4. Run
npx @apollo/client-codemod-migrate-3-to-4 --parser tsx ./src/**/*.{ts,tsx}. gqlImport:gqlis no longer exported from@apollo/client/react; import it directly from@apollo/client.ApolloClientType: TheTCacheShapetype argument has been removed fromApolloClientusages.
New
- Local State Codegen Plugin: Generate resolver types for
LocalStateusing the@apollo/client-graphql-codegen/local-stateplugin. - Comprehensive Codemod: A codemod automates several key migration steps, including updating
HttpLinkconfiguration andLocalStatesetup.
Fixes Worth Knowing
- Corrected an issue where
networkStatuswasn’
TL;DR
Apollo Client v4 migration is now easier with a new codemod (code modification tool) that automates many upgrade steps, including configuration and import updates.
Breaking
uri,headers, andcredentialsmust be moved to thelinkoption and use a newHttpLinkinstance. (Configuration change)nameandversionare now part ofclientAwareness. (Configuration change)typeDefsandfragmentMatcheroptions are removed; uselocalStatewith aLocalStateinstance instead. (Configuration change)disableNetworkFetchesis renamed toprioritizeCacheValues. (Configuration change)- Legacy import paths (e.g.,
@apollo/client/main.cjs) are updated to new entry points. (Import change)
New
No new features.
Fixes Worth Knowing
No fixes worth knowing.
Before You Upgrade
Run the clientSetup codemod step to automate most configuration changes before updating to Apollo Client v4.
TL;DR
Apollo Client is preparing for version 4.0 with deprecation warnings on older APIs, helping developers identify code that will require updates.
Breaking
- APIs used with
client.query,client.mutate, andclient.subscribeare deprecated (methods for fetching/modifying data). - Using a
standbyfetch policy withclient.querynow triggers a warning (controls caching behavior).
Before You Upgrade
Review console warnings for deprecated API usage and plan migration paths to ensure compatibility with Apollo Client 4.0.