Skip to content

Releases: apollographql/apollo-client

v3.7.4

13 Jan 19:27
98cf6d1
Compare
Choose a tag to compare

Patch Changes

  • #10427 28d909cff Thanks @jerelmiller! - Ensure in-flight promises executed by useLazyQuery are rejected when useLazyQuery unmounts.

  • #10383 5c5ca9b01 Thanks @jerelmiller! - Ensure the onError callback is called when the errorPolicy is set to "all" and partial data is returned.

  • #10425 86e35a6d2 Thanks @jerelmiller! - Prefer the onError and onCompleted callback functions passed to the execute function returned from useMutation instead of calling both callback handlers.

v3.8.0-alpha.3

03 Aug 09:55
c357562
Compare
Choose a tag to compare
v3.8.0-alpha.3 Pre-release
Pre-release

3.8.0-alpha.3

Patch Changes

v3.8.0-alpha.2

03 Aug 09:55
4bacd74
Compare
Choose a tag to compare
v3.8.0-alpha.2 Pre-release
Pre-release

3.8.0-alpha.2

Minor Changes

v3.8.0-alpha.1

03 Aug 09:55
b37e596
Compare
Choose a tag to compare
v3.8.0-alpha.1 Pre-release
Pre-release

3.8.0-alpha.15

Patch Changes

3.8.0-alpha.14

3.8.0-alpha.13

Patch Changes

  • #10766 ffb179e55 Thanks @jerelmiller! - More robust typings for the data property returned from useSuspenseQuery when using returnPartialData: true or an errorPolicy of all or ignore. TData now defaults to unknown instead of any.

  • #10809 49d28f764 Thanks @jerelmiller! - Fixed the ability to use refetch and fetchMore with React's startTransition. The hook will now behave correctly by allowing React to avoid showing the Suspense fallback when these functions are wrapped by startTransition. This change deprecates the suspensePolicy option in favor of startTransition.

3.8.0-alpha.12

3.8.0-alpha.11

Minor Changes

  • #10567 c2ce6496c Thanks @benjamn! - Allow ApolloCache implementations to specify default value for assumeImmutableResults client option, improving performance for applications currently using InMemoryCache without configuring new ApolloClient({ assumeImmutableResults: true })

Patch Changes

  • #10672 932252b0c Thanks @jerelmiller! - Fix the compatibility between useSuspenseQuery and React's useDeferredValue and startTransition APIs to allow React to show stale UI while the changes to the variable cause the component to suspend.

    Breaking change

    nextFetchPolicy support has been removed from useSuspenseQuery. If you are using this option, remove it, otherwise it will be ignored.

3.8.0-alpha.10

3.8.0-alpha.1

Patch Changes

v3.7.3

15 Dec 18:42
2f79f03
Compare
Choose a tag to compare

Patch Changes

  • #10334 7d923939d Thanks @jerelmiller! - Better handle deferred queries that have cached or partial cached data for them

  • #10368 46b58e976 Thanks @alessbell! - Fix: unblocks support for defer in mutations

    If the @defer directive is present in the document passed to mutate, the Promise will resolve with the final merged data after the last multipart chunk has arrived in the response.

v3.8.0-alpha.0

03 Aug 09:55
34c6256
Compare
Choose a tag to compare
v3.8.0-alpha.0 Pre-release
Pre-release

3.8.0-alpha.0

Minor Changes

Patch Changes

v3.7.2

06 Dec 17:22
Compare
Choose a tag to compare

Improvements (from CHANGELOG.md)

  • Only show dev tools suggestion in the console when connectToDevTools is true.
    @chris110408 in #10258

  • Pass TCache generic to MutationHookOptions for better type support in useMutation.
    @igrlk in #10223

  • Add name property to ApolloError to ensure better type safety and help error reporting tools better identify the error.
    @aaronadamsCA in #9323

  • Export a ModifierDetails type for the details parameter of a Modifier function.
    @KeithGillette in #7133

  • Revert use of cloneDeep to clone options when fetching queries.
    @MrDoomBringer in #10215

What's Changed (auto-generated by GitHub)

New Contributors

Full Changelog: v3.7.1...v3.7.2

3.7.1

20 Oct 20:18
e6ad3c9
Compare
Choose a tag to compare

Bug fixes (from CHANGELOG.md)

  • Fix issue where loading remains true after observer.refetch is called repeatedly with different variables when the same data are returned.
    @alessbell in #10143

  • Fix race condition where useFragment_experimental could receive cache updates before initially calling cache.watch in useEffect.
    @benjamn in #10212

What's Changed (auto-generated by GitHub)

New Contributors (auto-generated by GitHub)

Full Changelog: v3.7.0...v3.7.1

v3.7.0

30 Sep 17:30
9134aaf
Compare
Choose a tag to compare

New Features (from CHANGELOG.md)

  • Implement preview support for the @defer directive.
    @alessbell and @benjamn in #10018

  • Implement useFragment_experimental hook, which represents a lightweight live binding into the ApolloCache, and never triggers network requests of its own.
    @benjamn in #8782

  • Allow registering named fragments with InMemoryCache to support using ...NamedFragment in queries without redeclaring NamedFragment repeatedly in every query that uses it.
    @benjamn in #9764

  • Support onError callback for useSubscription hook.
    @jeroenvisser101 in #9495

Improvements (from CHANGELOG.md)

  • Delay calling onCompleted and onError callbacks passed to useQuery using Promise.resolve().then(() => ...) to fix issue #9794.
    @dylanwulf in #9823

  • Replace concast.cleanup method with simpler concast.beforeNext API, which promises to call the given callback function just before the next result/error is delivered. In addition, concast.removeObserver no longer takes a quietly?: boolean parameter, since that parameter was partly responsible for cleanup callbacks sometimes not getting called.
    @benjamn in #9718

  • Allow preserving header name capitalization when creating an HttpLink with createHttpLink({ uri, preserveHeaderCase: true }). Otherwise, header names are converted to lowercase to prevent case-sensitivity bugs.
    @MrDoomBringer in #9891

  • Make queries with a pollInterval respect the no-cache fetch policy, instead of writing polled results into the cache.
    @MrDoomBringer in #10020

  • Deprecate the onSubscriptionData callback in favor of a new onData callback for the useSubscription hook. Deprecate the onSubscriptionComplete callback in favor of a new onComplete callback for the useSubscription hook.
    @jerelmiller in #10134

Potentially disruptive (from CHANGELOG.md)

  • The optional subscribeAndCount testing utility exported from @apollo/client/testing/core now takes a single generic TResult type parameter, instead of TData. This type will typically be inferred from the observable argument type, but if you have any explicit calls to subscribeAndCount<TData>(...) in your own codebase, you may need to adjust those calls accordingly.
    @benjamn in #9718

What's Changed (auto-generated by GitHub)

New Contributors 🎉 🙌 🥳

Full Changelog: v3.6.10...v3.7.0

v3.6.10

29 Sep 23:49
5b29ea6
Compare
Choose a tag to compare

Improvements (from CHANGELOG.md)

  • The client options (variables, context, etc.) used for mutation calls are now available as the second argument to the onCompleted and onError callback functions.
    @MrDoomBringer in #10052

What's Changed

New Contributors

Full Changelog: v3.6.9...v.3.6.10