@apollo/client
Advanced tools
Changelog
Apollo Client 3.1.3
result.data
(rather than all properties of result
) when settling cache feuds. <br/>
@danReynolds in #6777import
declarations to use Apollo Client 3.x packages. Instructions. <br/>
@dminkovsky and @jcreighton in #6486Changelog
Apollo Client 3.1.0
Rework interdependencies between @apollo/client/*
entry points, so that CommonJS and ESM modules are supported equally well, without any duplication of shared code. <br/>
@benjamn in #6656 and
#6657
Tolerate !==
callback functions (like onCompleted
and onError
) in useQuery
options, since those functions are almost always freshly evaluated each time useQuery
is called. <br/>
@hwillson and @benjamn in #6588
Respect context.queryDeduplication
if provided, and otherwise fall back to client.deduplication
(as before). <br/>
@igaloly in #6261 and
@Kujawadl in #6526
Refactor ObservableQuery#getCurrentResult
to reenable immediate delivery of warm cache results. As part of this refactoring, the ApolloCurrentQueryResult
type was eliminated in favor of ApolloQueryResult
. <br/>
@benjamn in #6710
Avoid clobbering defaultOptions
with undefined
values. <br/>
@benjamn in #6715
Apollo Client will no longer modify options.fetchPolicy
unless you pass options.nextFetchPolicy
to request an explicit change in FetchPolicy
after the current request. Although this is technically a breaking change, options.nextFieldPolicy
makes it easy to restore the old behavior (by passing cache-first
). <br/>
@benjamn in #6712, reverting #6353
Errors of the form Invariant Violation: 42
thrown in production can now be looked up much more easily, by consulting the auto-generated @apollo/client/invariantErrorCodes.js
file specific to your @apollo/client
version. <br/>
@benjamn in #6665
Make the client
field of the MutationResult
type non-optional, since it is always provided. <br/>
@glasser in #6617
Allow passing an asynchronous options.renderFunction
to getMarkupFromTree
. <br/>
@richardscarrott in #6576
Ergonomic improvements for merge
and keyArgs
functions in cache field policies. <br/>
@benjamn in #6714