Change8

Migrating to Apollo Client @apollo/client@4.0.0-rc.10

Version @apollo/client@4.0.0-rc.10 introduces 2 breaking changes. This guide details how to update your code.

Released: 8/13/2025

2
Breaking Changes
3
Migration Steps
5
Affected Symbols

⚠️ Check Your Code

If you use any of these symbols, you need to read this guide:

DataMaskingMaskedMaskedDocumentNodeTypeOverridesGraphQLCodegenDataMasking

Breaking Changes

Issue #1

The default data masking type changed to an identity type; projects that relied on GraphQL Codegen generated masked types must now opt‑in via declaration merging on the `TypeOverrides` interface, otherwise type errors will occur.

Issue #2

The `mode` property on the `DataMasking` interface has been removed and is ignored; any code that sets `mode` must delete that property. The `Masked` and `MaskedDocumentNode` types have also been removed, causing compile errors if they are imported.

Migration Steps

  1. 1
    Add a declaration merging block for `@apollo/client` that extends `GraphQLCodegenDataMasking.TypeOverrides` as shown in the release notes.
  2. 2
    Remove any `mode` property from your `DataMasking` type declarations.
  3. 3
    Delete imports or usages of the now‑removed `Masked` and `MaskedDocumentNode` types.

Release Summary

This release makes data‑masking types opt‑in only, removes the `mode` option and the `Masked`/`MaskedDocumentNode` types, and requires migration steps to adjust type declarations.

Need More Details?

View the full release notes and all changes for Apollo Client @apollo/client@4.0.0-rc.10.

View Full Changelog