@apollo/client
4.3.5 · 19 Oct 2026MIT5.3M / weekRepositoryHomepagenpmAtom feed
3.14.1 is the newest release of 3.x.
In short
1 breaking4 new5 fixed
- breaking
Apollo Client will no longer modify
options.fetchPolicyunless you passoptions.nextFetchPolicyto request an explicit change inFetchPolicyafter the current request. Although this is technically a breaking change,options.nextFieldPolicymakes it easy to restore the old behavior (by passingcache-first).
Release note
Apollo Client 3.1.0
Bug Fixes
Rework interdependencies between
@apollo/client/*entry points, so that CommonJS and ESM modules are supported equally well, without any duplication of shared code.
@benjamn in #6656 and
#6657Tolerate
!==callback functions (likeonCompletedandonError) inuseQueryoptions, since those functions are almost always freshly evaluated each timeuseQueryis called.
@hwillson and @benjamn in #6588Respect
context.queryDeduplicationif provided, and otherwise fall back toclient.deduplication(as before).
@igaloly in #6261 and
@Kujawadl in #6526Refactor
ObservableQuery#getCurrentResultto reenable immediate delivery of warm cache results. As part of this refactoring, theApolloCurrentQueryResulttype was eliminated in favor ofApolloQueryResult.
@benjamn in #6710Avoid clobbering
defaultOptionswithundefinedvalues.
@benjamn in #6715
Improvements
- breaking
Apollo Client will no longer modify
options.fetchPolicyunless you passoptions.nextFetchPolicyto request an explicit change inFetchPolicyafter the current request. Although this is technically a breaking change,options.nextFieldPolicymakes it easy to restore the old behavior (by passingcache-first).
@benjamn in #6712, reverting #6353 Errors of the form
Invariant Violation: 42thrown in production can now be looked up much more easily, by consulting the auto-generated@apollo/client/invariantErrorCodes.jsfile specific to your@apollo/clientversion.
@benjamn in #6665Make the
clientfield of theMutationResulttype non-optional, since it is always provided.
@glasser in #6617Allow passing an asynchronous
options.renderFunctiontogetMarkupFromTree.
@richardscarrott in #6576Ergonomic improvements for
mergeandkeyArgsfunctions in cache field policies.
@benjamn in #6714