Skip to content

Conversation

github-actions[bot]
Copy link
Contributor

@github-actions github-actions bot commented Jul 15, 2025

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and publish to npm yourself or setup this action to publish automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to release-4.0, this PR will be updated.

⚠️⚠️⚠️⚠️⚠️⚠️

release-4.0 is currently in pre mode so this branch has prereleases rather than normal releases. If you want to exit prereleases, run changeset pre exit on release-4.0.

⚠️⚠️⚠️⚠️⚠️⚠️

Releases

@apollo/[email protected]

Patch Changes

  • #12775 454ec78 Thanks @jerelmiller! - Don't export gql from @apollo/client/react entrypoint. Import from @apollo/client instead.

@apollo/[email protected]

Major Changes

  • #12776 bce9b74 Thanks @jerelmiller! - Report masked fragments as complete even when a nested masked fragment contains partial data.

  • #12774 511b4f3 Thanks @jerelmiller! - Apply document transforms before reading data from the cache for client.readQuery, client.readFragment, client.watchFragment, useFragment, and useSuspenseFragment.

    NOTE: This change does not affect the equivalent cache.* APIs. To read data from the cache without first running document transforms, run cache.readQuery, cache.readFragment, etc.

Minor Changes

Patch Changes

  • #12776 bce9b74 Thanks @jerelmiller! - cache.watchFragment now returns an Unmasked<TData> result since cache.watchFragment does not mask fragment spreads.

  • #12370 0517163 Thanks @phryneas! - InMemoryCache: Fields with an empty argument object are now saved the same way as fields without arguments.

    Previously, it was possible that the reponses for these two queries would be stored differently in the cache:

    query PlainAccess {
      myField
    }

    would be stored as myField
    and

    query AccessWithoutOptionalArgument($optional: String) {
      myField(optional: $optional)
    }

    would be stored as myField({"optional":"Foo"}) if called with {optional: "Foo"} and as myField({}) if called without the optional argument.

    The cases myField and myField({}) are equivalent from the perspective of a GraphQL server, and so in the future both of these will be stored as myField in the cache.

  • #12775 454ec78 Thanks @jerelmiller! - Don't export gql from @apollo/client/react entrypoint. Import from @apollo/client instead.

  • #12761 db6f7c3 Thanks @phryneas! - Deprecate second argument to readFragment and readQuery - optimistic should be passed as part of the object in the first argument instead.

Copy link

pkg-pr-new bot commented Jul 15, 2025

npm i https://pkg.pr.new/apollographql/apollo-client/@apollo/client@12778
npm i https://pkg.pr.new/apollographql/apollo-client/@apollo/client-codemod-migrate-3-to-4@12778

commit: ba8c109

@apollogithubactionsbot apollogithubactionsbot bot force-pushed the changeset-release/release-4.0 branch from 8d4b351 to 7a6608a Compare July 15, 2025 15:48
Copy link
Contributor Author

github-actions bot commented Jul 15, 2025

size-limit report 📦

Path Size
import { ApolloClient, InMemoryCache, HttpLink } from "@apollo/client" (CJS) 42.8 KB (-0.04% 🔽)
import { ApolloClient, InMemoryCache, HttpLink } from "@apollo/client" (production) (CJS) 37.91 KB (-0.05% 🔽)
import { ApolloClient, InMemoryCache, HttpLink } from "@apollo/client" 32.67 KB (+0.01% 🔺)
import { ApolloClient, InMemoryCache, HttpLink } from "@apollo/client" (production) 27.09 KB (-0.03% 🔽)
import { ApolloProvider } from "@apollo/client/react" 5.7 KB (+0.02% 🔺)
import { ApolloProvider } from "@apollo/client/react" (production) 960 B (0%)
import { useQuery } from "@apollo/client/react" 7 KB (+0.05% 🔺)
import { useQuery } from "@apollo/client/react" (production) 2.23 KB (-0.05% 🔽)
import { useLazyQuery } from "@apollo/client/react" 6.88 KB (0%)
import { useLazyQuery } from "@apollo/client/react" (production) 2.13 KB (0%)
import { useMutation } from "@apollo/client/react" 6.22 KB (0%)
import { useMutation } from "@apollo/client/react" (production) 1.48 KB (+0.14% 🔺)
import { useSubscription } from "@apollo/client/react" 6.57 KB (0%)
import { useSubscription } from "@apollo/client/react" (production) 1.79 KB (-0.82% 🔽)
import { useSuspenseQuery } from "@apollo/client/react" 8.34 KB (0%)
import { useSuspenseQuery } from "@apollo/client/react" (production) 3.62 KB (-0.03% 🔽)
import { useBackgroundQuery } from "@apollo/client/react" 8.13 KB (+0.07% 🔺)
import { useBackgroundQuery } from "@apollo/client/react" (production) 3.38 KB (+0.03% 🔺)
import { useLoadableQuery } from "@apollo/client/react" 8.07 KB (+0.02% 🔺)
import { useLoadableQuery } from "@apollo/client/react" (production) 3.36 KB (+0.03% 🔺)
import { useReadQuery } from "@apollo/client/react" 6.37 KB (-0.02% 🔽)
import { useReadQuery } from "@apollo/client/react" (production) 1.63 KB (+0.19% 🔺)
import { useFragment } from "@apollo/client/react" 6.45 KB (+0.02% 🔺)
import { useFragment } from "@apollo/client/react" (production) 1.69 KB (+0.06% 🔺)

@apollogithubactionsbot apollogithubactionsbot bot force-pushed the changeset-release/release-4.0 branch from 7a6608a to 1de8991 Compare July 16, 2025 07:50
@apollo-librarian
Copy link

apollo-librarian bot commented Jul 16, 2025

⚠️ Docs preview not attached to branch

The preview was not built because the PR's base branch release-4.0 is not in the list of sources.

An Apollo team member can comment one of the following commands to dictate which branch to attach the preview to:

  • !docs set-base-branch version-2.6
  • !docs set-base-branch main

Build ID: 0c3a14c1891deef6c75abecb

@apollogithubactionsbot apollogithubactionsbot bot force-pushed the changeset-release/release-4.0 branch from 1de8991 to 32f946b Compare July 17, 2025 20:21
@apollo-librarian
Copy link

🛠️ Docs preview building...

The preview is currently being built.

Build ID: b7a1d6b335c1f5098ee32518

@apollogithubactionsbot apollogithubactionsbot bot force-pushed the changeset-release/release-4.0 branch from 32f946b to 07c8e4a Compare July 17, 2025 21:55
@apollo-librarian
Copy link

🛠️ Docs preview building...

The preview is currently being built.

Build ID: b9c39504ca77964d8cad0af8

@apollogithubactionsbot apollogithubactionsbot bot force-pushed the changeset-release/release-4.0 branch from 07c8e4a to 41a1972 Compare July 18, 2025 09:02
@apollo-librarian
Copy link

🛠️ Docs preview building...

The preview is currently being built.

Build ID: b8225b04bc34b46bc2019ca4

@apollogithubactionsbot apollogithubactionsbot bot force-pushed the changeset-release/release-4.0 branch from 41a1972 to ba8c109 Compare July 18, 2025 09:30
@apollo-librarian
Copy link

🛠️ Docs preview building...

The preview is currently being built.

Build ID: 0c3a14c1891deef6c75abecb

@github-actions github-actions bot added the auto-cleanup 🤖 label Jul 18, 2025
@jerelmiller jerelmiller merged commit 8c8734a into release-4.0 Jul 18, 2025
43 of 46 checks passed
@jerelmiller jerelmiller deleted the changeset-release/release-4.0 branch July 18, 2025 20:53
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 18, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant