Skip to content

Release 4.0 #12201

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 285 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
285 commits
Select commit Hold shift + click to select a range
a6a978e
Remove leftover of `addTypename` (#12406)
PowerKiKi Mar 6, 2025
2545a54
Remove unneeded devtools code (#12397)
jerelmiller Mar 6, 2025
cad5117
Build tooling 3/? - export conditions (#12385)
phryneas Mar 7, 2025
903c3ef
Use `{}` instead of `Object.create(null)` (#12402)
jerelmiller Mar 7, 2025
5500c1f
Organize imports (#12414)
phryneas Mar 7, 2025
388ba97
Minor refactor (#12390)
jerelmiller Mar 10, 2025
16ee78f
Merge branch 'main' into release-4.0
phryneas Mar 11, 2025
ebbf640
fixup
phryneas Mar 11, 2025
9ec9584
fix up incorrectly merged tests
phryneas Mar 11, 2025
6aa6fd3
Switch to RxJS (#12384)
jerelmiller Mar 11, 2025
00f3d0a
Consolidate error properties (#12396)
jerelmiller Mar 11, 2025
8b1390b
[Refactor] Move tracking of `networkStatus` into `ObservableQuery` (#…
jerelmiller Mar 11, 2025
e6af35e
Update `useLazyQuery` with planned breaking changes (#12367)
jerelmiller Mar 12, 2025
8cf5077
Separate error objects (#12398)
jerelmiller Mar 12, 2025
7675c3b
Merge branch 'main' into release-4.0
jerelmiller Mar 13, 2025
2ff66d0
Remove `ObservableQuery.result` (#12430)
jerelmiller Mar 13, 2025
92622cd
Move build before size limits (#12434)
jerelmiller Mar 13, 2025
abed922
Remove the `urql` multipart subscriptions utilities (#12428)
jerelmiller Mar 13, 2025
0d825be
Remove check for `WeakMap`, `WeakSet` and symbols (#12388)
jerelmiller Mar 13, 2025
c7c2f61
ObservableQuery - implement InteropObservable interface (#12432)
phryneas Mar 13, 2025
35ae237
Use `firstValueFrom(from(observableQuery))` where appropriate (#12435)
jerelmiller Mar 13, 2025
a0e0d2e
Version Packages (alpha) (#12221)
github-actions[bot] Mar 13, 2025
4779dc7
remove React Native polyfills (#12437)
phryneas Mar 14, 2025
cdf8ed4
some byte shaving for the prod build (#12436)
phryneas Mar 14, 2025
b86e50b
Remove workarounds for streaming with non-WhatWG response bodies (#12…
phryneas Mar 14, 2025
5089516
add a react-server entry point, remove `rehackt` (#12438)
phryneas Mar 14, 2025
76c8fd2
Version Packages (alpha) (#12439)
github-actions[bot] Mar 14, 2025
cc6cc1e
switch JS syntax to modern JS in a few places (#12441)
phryneas Mar 14, 2025
674bb64
Disable warnings in mock link for flaky test (#12443)
jerelmiller Mar 14, 2025
c5ead08
Remove object canonization (#12442)
jerelmiller Mar 17, 2025
925548a
[4.0] fix commonJS build (#12454)
phryneas Mar 18, 2025
876d070
Remove `TCacheShape` generic argument from `ApolloClient` and `TSeria…
jerelmiller Mar 19, 2025
77e1b13
Default `TData` type to `unknown` instead of `any` (#12451)
jerelmiller Mar 19, 2025
ab920d2
Remove `defaultOptions` from `useQuery` (#12446)
jerelmiller Mar 19, 2025
795fd18
Version Packages (alpha) (#12449)
github-actions[bot] Mar 19, 2025
0595f39
Remove `called` property from `useQuery` (#12464)
jerelmiller Mar 20, 2025
32e85ea
Unify error behavior for queries (#12457)
jerelmiller Mar 20, 2025
5e8ec56
Merge remote-tracking branch 'origin/main' into release-4.0
jerelmiller Mar 20, 2025
2f5506b
Fixup tests
jerelmiller Mar 20, 2025
cb2f86c
Version Packages (alpha) (#12467)
github-actions[bot] Mar 20, 2025
a132163
Colocate and flatten hook types (#12465)
jerelmiller Mar 24, 2025
d32902f
replace `client.disableNetworkFetches` with `queryManager.prioritizeC…
phryneas Mar 24, 2025
054f561
Refactor `useMutation` tests to use full result matchers and snapshot…
jerelmiller Mar 24, 2025
3868df8
Remove `setOptions` and tweak `reobserve` (#12463)
jerelmiller Mar 24, 2025
3f384a9
Version Packages (alpha) (#12473)
github-actions[bot] Mar 24, 2025
f159336
Refactor `useSubscription` tests to use render stream and more strict…
jerelmiller Mar 25, 2025
b695e5e
Split out SSR-specific code from `useQuery` hook, remove `RenderPromi…
phryneas Mar 27, 2025
5df64e2
Use toHaveBeenCalledWith to try and prevent flakes (#12492)
jerelmiller Mar 27, 2025
06ad7d8
Reduce console noise in `ApolloClient/general` tests (#12493)
jerelmiller Mar 27, 2025
eb489ff
reduce size of api explorer reports (#12489)
phryneas Mar 28, 2025
c7708ea
Refactor away `createMakeWatchQueryOptions` (#12494)
jerelmiller Mar 28, 2025
82dabdb
Refactor away `getObsQueryOptions` (#12495)
jerelmiller Mar 28, 2025
741570b
Refactor `useQuery`: Combine hooks (#12496)
jerelmiller Mar 28, 2025
39e2775
Merge branch 'main' into release-4.0
jerelmiller Mar 28, 2025
7e8380b
Use `toEqualStrictTyped` in `useSuspenseQuery` tests (#12498)
jerelmiller Mar 31, 2025
3de63eb
Unify error behavior of `client.mutate` and update its type (#12475)
jerelmiller Mar 31, 2025
6afff60
Unify subscription error behavior and update emitted type (#12476)
jerelmiller Mar 31, 2025
5ea6a45
Remove deprecated `onSubscriptionData`, `onSubscriptionComplete` call…
jerelmiller Mar 31, 2025
3f61b7d
Version Packages (alpha) (#12490)
github-actions[bot] Mar 31, 2025
c98b633
adjust ssr to work with new static rendering methods (#12488)
phryneas Apr 1, 2025
d94b0cf
update to React 19.1.0 (#12502)
phryneas Apr 1, 2025
9a8b9ce
Remove unnecessary properties from promise-based query APIs (#12484)
jerelmiller Apr 1, 2025
d338303
Throw an error if the link chain completes without emitting a value (…
jerelmiller Apr 1, 2025
ff2cbe1
Add `data` property to `CombinedGraphQLErrors` (#12497)
jerelmiller Apr 1, 2025
4665b0c
Version Packages (alpha) (#12501)
github-actions[bot] Apr 1, 2025
963c985
Minor `QueryInfo` refactor (#12506)
jerelmiller Apr 1, 2025
f79bf70
import from `@apollo/client` in tests where possible (#12503)
phryneas Apr 2, 2025
e70a572
replace wildcard re-exports with individual exports (#12508)
phryneas Apr 2, 2025
a7f5f0c
re-export from official entrypoints where possible (#12509)
phryneas Apr 2, 2025
38a61b7
tests: import from entry points where possible, add `@apollo/client/t…
phryneas Apr 2, 2025
1645c24
Remove `toEqual*` matchers in favor of `toEqualStrictTyped` (#12514)
jerelmiller Apr 2, 2025
923cfdd
Remove type-specific `toEmit*` matchers in favor of `toEmitStrictType…
jerelmiller Apr 2, 2025
4418600
Rename `toEqualStrictTyped` and `toEmitStrictTyped` (#12516)
jerelmiller Apr 2, 2025
fa4348a
Remove `toEmitMatchedValue` in favor or `toEmitTypedValue` (#12517)
jerelmiller Apr 2, 2025
9c3207c
remove `react/context|hooks|parser` entry points, remove `parser` uti…
phryneas Apr 3, 2025
73d960b
Fix warnings emitted to console from `ObservableQuery` tests (#12522)
jerelmiller Apr 3, 2025
eec20d1
Silence more core tests warnings (#12523)
jerelmiller Apr 3, 2025
e794dd8
Version Packages (alpha) (#12521)
github-actions[bot] Apr 3, 2025
4d1ab3a
run CI tests against compiled bundles (#12519)
phryneas Apr 4, 2025
c5ff2a4
Merge remote-tracking branch 'origin/main' into release-4.0
phryneas Apr 9, 2025
b18ff01
Merge remote-tracking branch 'origin/main' into release-4.0
phryneas Apr 10, 2025
391af1d
prefer `@apollo/client` over `@apollo/client/core` (#12526)
phryneas Apr 10, 2025
8785186
Refactor MockLink and add many missing tests (#12525)
jerelmiller Apr 10, 2025
2973e2a
Remove `newData` option from `MockLink` (#12530)
jerelmiller Apr 10, 2025
7784b46
Combine `variables` and `variablesMatcher` in `MockLink` (#12531)
jerelmiller Apr 10, 2025
ae0dcad
Add support for callback on `delay` and default to random delay (#12532)
jerelmiller Apr 10, 2025
73221d8
Remove `onError` and `setOnError` from `ApolloLink` (#12533)
jerelmiller Apr 10, 2025
dd0d6d6
Conslidate errors on `error` property in `onError` link (#12539)
jerelmiller Apr 10, 2025
11e884b
Merge remote-tracking branch 'origin/main' into release-4.0
jerelmiller Apr 10, 2025
3d76056
Fix size limits from merge
jerelmiller Apr 10, 2025
9b15b9b
Version Packages (alpha) (#12545)
github-actions[bot] Apr 10, 2025
afb4fce
Remove `partial` property returned from `useLazyQuery` (#12542)
jerelmiller Apr 11, 2025
e809b71
Change `notifyOnNetworkStatusChange` default to `true` (#12512)
jerelmiller Apr 11, 2025
e14205a
Emit initial loading state when `notifyOnNetworkStatusChange` is `tru…
jerelmiller Apr 11, 2025
90de488
Version Packages (alpha) (#12549)
github-actions[bot] Apr 11, 2025
8b1de2e
Fix value of `ObservableQuery.variables` to be `undefined` when varia…
jerelmiller Apr 11, 2025
2597494
Fix import from `@apollo/client/core` (#12553)
jerelmiller Apr 11, 2025
a40ebdf
Revert "Fix value of `ObservableQuery.variables` to be `undefined` wh…
jerelmiller Apr 14, 2025
28e857f
Fix test flake introduced by changes to `MockLink` (#12565)
jerelmiller Apr 16, 2025
5dffbbe
Add static `is` methods to error types for type narrowing (#12546)
jerelmiller Apr 17, 2025
51d26ae
Update message format for `CombinedGraphQLErrors` and `CombinedProtoc…
jerelmiller Apr 17, 2025
ac26b1b
fix up some type exports in `/core` (#12568)
phryneas Apr 17, 2025
49ace0e
Better types for `variables` throughout the client (#12559)
jerelmiller Apr 17, 2025
90bf0e6
Remove unsupported `client.query` options (#12562)
jerelmiller Apr 17, 2025
99d72bf
Add a new helper that detects network errors from the link chain (#12…
jerelmiller Apr 17, 2025
dde5f0c
Version Packages (alpha) (#12570)
github-actions[bot] Apr 17, 2025
50dc13f
Update tests that check calls to internal `QueryManager` methods (#12…
jerelmiller Apr 18, 2025
ce4b488
Don't call `broadcastQueries` when a query is stopped (#12566)
jerelmiller Apr 22, 2025
0098ec9
Export `gql` from `@apollo/client/react` (#12574)
jerelmiller Apr 22, 2025
3dc50e6
Better support for required `variables` in `useMutation` (#12572)
jerelmiller Apr 22, 2025
a92ff78
More robust link context types with access to `client` (#12576)
jerelmiller Apr 23, 2025
6a37dc5
Version Packages (alpha) (#12580)
github-actions[bot] Apr 23, 2025
605db8e
Remove `typeDefs` option (#12586)
jerelmiller Apr 29, 2025
eed825a
Remove `TContext` generic argument (#12588)
jerelmiller Apr 29, 2025
15f5a1c
Require the `link` option when instantiating `HttpLink` (#12589)
jerelmiller Apr 29, 2025
a005e82
Drop `graphql` v15 as a peer dependency (#12590)
jerelmiller Apr 29, 2025
072e98f
rewrite `refetchQueries` with deterministic order of `onQueryUpdated`…
phryneas Apr 29, 2025
a7e7383
Rename `@apollo/client/link/core` entrypoint (#12591)
jerelmiller Apr 29, 2025
b3e9d2f
Version Packages (alpha) (#12592)
github-actions[bot] Apr 29, 2025
5b9cc2b
new matchers: `toRerenderWithSimilarSnapshot` and `toRerenderWithStri…
phryneas May 5, 2025
60bb49c
Remove experimental testing utilities (#12595)
jerelmiller May 6, 2025
8892cc2
avoid building jest config as part of the compile step (#12608)
phryneas May 7, 2025
e4a3ecf
Remove code that strips `@client` fields in `HttpLink`/`BatchHttpLink…
jerelmiller May 14, 2025
34ff6aa
Move internal utilities to `utilities/internal` (#12600)
jerelmiller May 14, 2025
5463f0b
Version Packages (alpha) (#12610)
github-actions[bot] May 14, 2025
0a99d9c
refactor test for loading/emit changes and `nextFetchPolicy` (#12620)
phryneas May 15, 2025
0c9468b
Remove removeClientSetsFromDocument utility in favor of removeDirecti…
jerelmiller May 16, 2025
7c0cfdc
New build step: @deprecated tag for @internal apis (#12630)
phryneas May 20, 2025
54b2004
Remove `postprocessDist` compile step (#12629)
phryneas May 20, 2025
d2851e2
Extract `localState` to own module and require opt-in. Add additional…
jerelmiller May 20, 2025
c3fceda
Rewrite observable query subscription logic (#12556)
phryneas May 21, 2025
15b6f12
Update incorrect changesets (#12638)
jerelmiller May 21, 2025
8af7baa
Merge remote-tracking branch 'origin/main' into release-4.0
jerelmiller May 21, 2025
12b26bf
Version Packages (alpha) (#12634)
github-actions[bot] May 21, 2025
e48485d
package.json exports: use extension substitution for types (#12628)
phryneas May 22, 2025
1bdf489
Move internal testing utilities to `/internal` and remove other depre…
jerelmiller May 22, 2025
b147cac
drop `fetchPolicy: "standby"` pre-subscription loading state (#12631)
phryneas May 23, 2025
d2a60d4
only advance `previousData` if `data` changed (#12637)
phryneas May 23, 2025
1326540
Version Packages (alpha) (#12641)
github-actions[bot] May 23, 2025
7e8cf7a
Exclude `testing/internal` entrypoint in build (#12646)
phryneas May 27, 2025
fe2f005
Add more strict compatibility with GraphQL over HTTP spec (#12644)
jerelmiller May 28, 2025
453a262
add package scaffolding for codegen plugin (#12651)
phryneas May 28, 2025
ea633a1
Add `LocalState` codegen plugin (#12617)
jerelmiller May 28, 2025
7dd6721
Update version command (#12655)
jerelmiller May 28, 2025
777fbc7
Update version command again (#12656)
jerelmiller May 28, 2025
c842d8d
Revert to original command (#12657)
jerelmiller May 28, 2025
ebc41db
Version Packages (alpha) (#12658)
github-actions[bot] May 28, 2025
e5b4c50
Move publish command to script
jerelmiller May 28, 2025
fca4d2c
Version Packages (alpha) - empty commit to force publish
jerelmiller May 28, 2025
1192e21
Remove npm run from command
jerelmiller May 28, 2025
9efd730
Version Packages (alpha) - empty commit to force publish
jerelmiller May 28, 2025
ff262ac
Fix postrelease steps in prerelease workflow (#12659)
jerelmiller May 29, 2025
9bb9947
Add tests for changing variables with partial data (#12664)
jerelmiller Jun 2, 2025
9bfb51f
Cancel running `ObservableQuery` link on unsubscribe (#12633)
phryneas Jun 3, 2025
0be92ad
Add `dataState` to result types (#12649)
jerelmiller Jun 3, 2025
3f58bf3
Version Packages (alpha) (#12669)
github-actions[bot] Jun 3, 2025
c125324
Add npm token before dist tag (#12671)
jerelmiller Jun 3, 2025
0a880ea
Provide a mechanism to override the `DataMasking` types. (#12670)
phryneas Jun 4, 2025
1f672c9
adjust integration test (#12674)
phryneas Jun 4, 2025
85dc598
Version Packages (alpha) (#12672)
github-actions[bot] Jun 5, 2025
01512f2
Allow subscriptions to be deduplicated (#12663)
jerelmiller Jun 5, 2025
ca2d63b
Version Packages (alpha) (#12676)
github-actions[bot] Jun 5, 2025
91a876b
Remove `queryRef.toPromise` in favor of `preloadQuery.toPromise` (#12…
jerelmiller Jun 6, 2025
a70fac6
change tracking behaviour for `QueryInfo` (#12647)
phryneas Jun 6, 2025
8f1d974
remove `ObservableQuery.queryId`, return `Set` from `getObservableQue…
phryneas Jun 6, 2025
ad641e4
Version Packages (alpha) (#12680)
github-actions[bot] Jun 6, 2025
0cb1601
move all `mark*Result` functions into `QueryInfo`, clean up `QueryInf…
phryneas Jun 9, 2025
e52915b
temporarily disable the Next.js integration test (#12689)
phryneas Jun 10, 2025
dc4b1d0
`loading` is now `true `when a response is still streaming. Adds `Net…
jerelmiller Jun 10, 2025
3b74800
Remove warning for `cache.fragmentMatches` when applying data masking…
jerelmiller Jun 10, 2025
e697431
Remove `context` from `useLazyQuery` hook options (#12684)
jerelmiller Jun 10, 2025
2cfef3d
Remove remaining internal utils from public utils entrypoint (#12683)
jerelmiller Jun 10, 2025
7187540
Version Packages (alpha) (#12691)
github-actions[bot] Jun 10, 2025
5812759
Forbid aliasing fields to `__typename` or `__ac_*` (#12690)
phryneas Jun 12, 2025
bbb90c3
Better stack trace on failures with `toEmit*` matchers (#12695)
jerelmiller Jun 13, 2025
cee90ab
add support for Enhanced Client Awareness (#12673)
phryneas Jun 13, 2025
be77d1a
Add `accept` option to `HttpOptions` (#12698)
phryneas Jun 13, 2025
ddf196a
Version Packages (alpha) (#12696)
github-actions[bot] Jun 13, 2025
7e2db0b
Add test for changing variables with error returned with `notifyOnNet…
jerelmiller Jun 17, 2025
a60f411
Set `loading: false` with `cache-only` queries with no data in the ca…
jerelmiller Jun 18, 2025
8e96e08
Introduce pluggable incremental handlers (#12700)
phryneas Jun 18, 2025
9d42e2a
rework multipart response parsing, remove incremental references (#12…
phryneas Jun 18, 2025
ce35ea2
enable React compiler for hooks in ESM builds (#12499)
phryneas Jun 18, 2025
45dba43
Update persisted query link error handling to match the rest of the c…
jerelmiller Jun 18, 2025
f730f83
Add `extensions` to `CombinedGraphQLErrors` (#12711)
jerelmiller Jun 18, 2025
92212f2
Minor improvements to `useQuery`/`ObservableQuery` (#12703)
jerelmiller Jun 18, 2025
b181f98
Don't call `reobserve` when changing most options in `useQuery` and i…
jerelmiller Jun 18, 2025
0be0b3f
migrate links to classes (#12715)
phryneas Jun 18, 2025
0e39469
rework options & option handling for `ObservableQuery.fetchMore` (#12…
phryneas Jun 18, 2025
94e58ed
Downgrade minimum supported RxJS version (#12677)
jerelmiller Jun 18, 2025
bbb2b61
Don't allow `fetchMore` or updates to polling for `cache-only` querie…
jerelmiller Jun 18, 2025
44645d2
Version Packages (alpha) (#12710)
github-actions[bot] Jun 18, 2025
c8747eb
Prepare for rc release
github-actions[bot] Jun 18, 2025
ad88976
Add changeset to release `rc` (#12716)
jerelmiller Jun 18, 2025
b2b42dc
Version Packages (rc) (#12717)
github-actions[bot] Jun 18, 2025
ecfc02a
Really release rc (#12718)
jerelmiller Jun 18, 2025
8a62d6d
Remove bad changelog item
jerelmiller Jun 18, 2025
67d61ad
Merge branch 'main' into release-4.0
jerelmiller Jun 18, 2025
f1eba94
Version Packages (rc) (#12719)
github-actions[bot] Jun 18, 2025
2f578f8
Add test for changing variables with `network-only` fetch policy (#12…
jerelmiller Jun 19, 2025
1f9ed72
Bump codegen to rc (#12723)
jerelmiller Jun 19, 2025
525e30d
Reset codegen version for rc
jerelmiller Jun 19, 2025
449c3ea
Version Packages (rc) (#12724)
github-actions[bot] Jun 19, 2025
07a0c8c
Export `IgnoreModifier` (#12728)
jerelmiller Jun 23, 2025
699c830
Ensure a `refetch` that changes variables and returns deep equal resu…
jerelmiller Jun 24, 2025
89ac725
Add `getMainDefinition` back to `@apollo/client/utilities` (#12725)
jerelmiller Jun 24, 2025
037979d
Don't warn for missing resolvers (#12734)
jerelmiller Jun 24, 2025
5159880
Remove remaining deprecations (#12735)
jerelmiller Jun 24, 2025
3bdf391
Version Packages (rc) (#12732)
github-actions[bot] Jun 24, 2025
b184754
Fix type of `error` argument for `onError` callback to `subscribeToMo…
jerelmiller Jun 25, 2025
b845906
4.0 import rename codemod (#12727)
jerelmiller Jun 25, 2025
1c6e03c
allow Complete and Partial datastate type overrides (#12740)
phryneas Jun 27, 2025
575bf3e
Improve `operation` type for `SetContextLink` (#12742)
jerelmiller Jun 27, 2025
e1ca85e
Fix a bug where the new `operationType` property wasn't passed into `…
phryneas Jun 27, 2025
0e686a1
Version Packages (rc) (#12741)
github-actions[bot] Jun 27, 2025
9c859b0
Merge branch 'main' into release-4.0
phryneas Jun 30, 2025
b85818d
Add `refetchObservableQueries` aliased method (#12753)
jerelmiller Jun 30, 2025
0198870
Ship compiled hooks in `.../react/compiled`, inline runtime (#12731)
phryneas Jun 30, 2025
5ff16fb
Version Packages (rc) (#12754)
github-actions[bot] Jul 1, 2025
7a204f5
install packages in postrelease step so `semver` is available
phryneas Jul 1, 2025
5ce6a1d
fix docmodel command and docs build (#12758)
phryneas Jul 2, 2025
5fd2e7c
add `dataState` to `useFragment`, `DataValue` type to `useSuspenseFra…
phryneas Jul 8, 2025
978dda6
Version Packages (rc) (#12765)
github-actions[bot] Jul 8, 2025
454ec78
Don't export `gql` from `/react` entrypoint (#12775)
jerelmiller Jul 15, 2025
511b4f3
Apply document transforms on `client.read*` APIs (#12774)
jerelmiller Jul 15, 2025
29322a6
add a job to build & upload the docmodel
phryneas Jul 15, 2025
f29fb62
changeset categorization (#12744)
phryneas Jul 17, 2025
9f9ed93
ObservableQuery documentation updates (#12759)
phryneas Jul 17, 2025
bce9b74
Report masked fragment as complete for nested partial data + add `dat…
jerelmiller Jul 17, 2025
f738265
Fix changeset script (#12780)
jerelmiller Jul 17, 2025
0517163
`InMemoryCache`: store fields with an empty object of optional argume…
phryneas Jul 17, 2025
db6f7c3
document changes to the `ApolloClient` constructor (#12761)
phryneas Jul 18, 2025
634f7ea
more `DocumentationTypes`, get docs to compile (#12771)
phryneas Jul 18, 2025
8c8734a
Version Packages (rc) (#12778)
github-actions[bot] Jul 18, 2025
742b3a0
Add namespaces for client types (#12782)
jerelmiller Jul 22, 2025
84d3e78
Unify documentation, doc types and docblocks for all hooks (#12777)
phryneas Jul 22, 2025
2d1e3ea
enforce usage of `declare namespace` over `namespace` (#12784)
phryneas Jul 23, 2025
baa6bec
lint @inheritDoc and MDX for correct canonical references (#12785)
phryneas Jul 23, 2025
8ce31fa
remove DataProxy, inline in ApolloClient and Cache namespaces (#12787)
phryneas Jul 23, 2025
4179446
enforce `extends OperationVariables` for `TVariables` generics (#12788)
phryneas Jul 23, 2025
1fee553
documentation updates for `LocalState` (#12781)
phryneas Jul 23, 2025
1f26441
fix missing newline
phryneas Jul 23, 2025
24e98a1
remove `ApolloConsumer` render props component (#12793)
phryneas Jul 23, 2025
6e2ad09
Format docs with Prettier. Update docs with Prettier formatting (#12794)
jerelmiller Jul 23, 2025
0715c6a
address all current linter warnings (#12790)
phryneas Jul 24, 2025
f839817
fix `@inheritDoc` indentation (#12791)
phryneas Jul 24, 2025
9f4f775
format DocBlocks as Markdown (#12795)
phryneas Jul 24, 2025
a029e47
bump docs
BlenderDude Jul 25, 2025
7879a02
Fix <MinVersion> tags with inline children, parsed ## as text
BlenderDude Jul 25, 2025
bddc2c0
docs bump
BlenderDude Jul 25, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
635 changes: 199 additions & 436 deletions .api-reports/api-report-cache.api.md

Large diffs are not rendered by default.

2,831 changes: 726 additions & 2,105 deletions .api-reports/api-report-core.api.md

Large diffs are not rendered by default.

211 changes: 89 additions & 122 deletions .api-reports/api-report-errors.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,171 +4,138 @@
```ts

import type { GraphQLError } from 'graphql';
import type { GraphQLErrorExtensions } from 'graphql';
import { ErrorLike } from '@apollo/client';
import type { FetchResult } from '@apollo/client';
import type { FormattedExecutionResult } from 'graphql';
import type { GraphQLFormattedError } from 'graphql';

// @public (undocumented)
export class ApolloError extends Error {
constructor({ graphQLErrors, protocolErrors, clientErrors, networkError, errorMessage, extraInfo, }: ApolloErrorOptions);
cause: ({
readonly message: string;
extensions?: GraphQLErrorExtensions[] | GraphQLFormattedError["extensions"];
} & Omit<Partial<Error> & Partial<GraphQLFormattedError>, "extensions">) | null;
export namespace CombinedGraphQLErrors {
// (undocumented)
clientErrors: ReadonlyArray<Error>;
export type MessageFormatter = (errors: ReadonlyArray<GraphQLFormattedError>, options: MessageFormatterOptions) => string;
// (undocumented)
extraInfo: any;
// (undocumented)
graphQLErrors: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
message: string;
// (undocumented)
name: string;
// Warning: (ae-forgotten-export) The symbol "ServerParseError" needs to be exported by the entry point index.d.ts
// Warning: (ae-forgotten-export) The symbol "ServerError" needs to be exported by the entry point index.d.ts
//
// (undocumented)
networkError: Error | ServerParseError | ServerError | null;
// (undocumented)
protocolErrors: ReadonlyArray<GraphQLFormattedError>;
export interface MessageFormatterOptions {
// (undocumented)
defaultFormatMessage: (errors: ReadonlyArray<GraphQLFormattedError>) => string;
// (undocumented)
result: FetchResult<unknown>;
}
}

// @public (undocumented)
export interface ApolloErrorOptions {
// (undocumented)
clientErrors?: ReadonlyArray<Error>;
// (undocumented)
errorMessage?: string;
// (undocumented)
extraInfo?: any;
// (undocumented)
graphQLErrors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
networkError?: Error | ServerParseError | ServerError | null;
// (undocumented)
protocolErrors?: ReadonlyArray<GraphQLFormattedError>;
}

// @public (undocumented)
interface DefaultContext extends Record<string, any> {
// @public
export class CombinedGraphQLErrors extends Error {
constructor(result: FormattedExecutionResult<any>);
constructor(result: FetchResult<any>, errors: ReadonlyArray<GraphQLFormattedError>);
readonly data: Record<string, unknown> | null | undefined;
readonly errors: ReadonlyArray<GraphQLFormattedError>;
readonly extensions: Record<string, unknown> | undefined;
static formatMessage: CombinedGraphQLErrors.MessageFormatter;
static is(error: unknown): error is CombinedGraphQLErrors;
}

// Warning: (ae-forgotten-export) The symbol "ExecutionPatchResultBase" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
interface ExecutionPatchIncrementalResult<TData = Record<string, any>, TExtensions = Record<string, any>> extends ExecutionPatchResultBase {
export namespace CombinedProtocolErrors {
// (undocumented)
data?: never;
export type MessageFormatter = (errors: ReadonlyArray<GraphQLFormattedError>, options: MessageFormatterOptions) => string;
// (undocumented)
errors?: never;
// (undocumented)
extensions?: never;
// Warning: (ae-forgotten-export) The symbol "IncrementalPayload" needs to be exported by the entry point index.d.ts
//
// (undocumented)
incremental?: IncrementalPayload<TData, TExtensions>[];
export interface MessageFormatterOptions {
// (undocumented)
defaultFormatMessage: (errors: ReadonlyArray<GraphQLFormattedError>) => string;
}
}

// @public (undocumented)
interface ExecutionPatchInitialResult<TData = Record<string, any>, TExtensions = Record<string, any>> extends ExecutionPatchResultBase {
// (undocumented)
data: TData | null | undefined;
// @public
export class CombinedProtocolErrors extends Error {
constructor(protocolErrors: Array<GraphQLFormattedError> | ReadonlyArray<GraphQLFormattedError>);
// (undocumented)
errors?: ReadonlyArray<GraphQLFormattedError>;
errors: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
// (undocumented)
incremental?: never;
static formatMessage: CombinedProtocolErrors.MessageFormatter;
static is(error: unknown): error is CombinedProtocolErrors;
}

// Warning: (ae-forgotten-export) The symbol "ExecutionPatchInitialResult" needs to be exported by the entry point index.d.ts
// Warning: (ae-forgotten-export) The symbol "ExecutionPatchIncrementalResult" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
type ExecutionPatchResult<TData = Record<string, any>, TExtensions = Record<string, any>> = ExecutionPatchInitialResult<TData, TExtensions> | ExecutionPatchIncrementalResult<TData, TExtensions>;

// @public (undocumented)
interface ExecutionPatchResultBase {
// (undocumented)
hasNext?: boolean;
}

// Warning: (ae-forgotten-export) The symbol "SingleExecutionResult" needs to be exported by the entry point index.d.ts
// Warning: (ae-forgotten-export) The symbol "ExecutionPatchResult" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
type FetchResult<TData = Record<string, any>, TContext = Record<string, any>, TExtensions = Record<string, any>> = SingleExecutionResult<TData, TContext, TExtensions> | ExecutionPatchResult<TData, TExtensions>;

// Warning: (ae-forgotten-export) The symbol "FetchResult" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
type FetchResultWithSymbolExtensions<T> = FetchResult<T> & {
export function graphQLResultHasProtocolErrors<T extends {}>(result: T): result is T & {
extensions: Record<string | symbol, any>;
};

// @public @deprecated (undocumented)
export type GraphQLErrors = ReadonlyArray<GraphQLError>;

// Warning: (ae-forgotten-export) The symbol "FetchResultWithSymbolExtensions" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
export function graphQLResultHasProtocolErrors<T>(result: FetchResult<T>): result is FetchResultWithSymbolExtensions<T>;
export function isErrorLike(error: unknown): error is ErrorLike;

// @public
export const LinkError: {
is: (error: unknown) => boolean;
};

// @public (undocumented)
interface IncrementalPayload<TData, TExtensions> {
// (undocumented)
data: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLFormattedError>;
// (undocumented)
extensions?: TExtensions;
export namespace LocalStateError {
// (undocumented)
label?: string;
// Warning: (ae-forgotten-export) The symbol "Path" needs to be exported by the entry point index.d.ts
//
// (undocumented)
path: Path;
export interface Options {
// (undocumented)
path?: Array<string | number>;
// (undocumented)
sourceError?: unknown;
}
}

// @public (undocumented)
export function isApolloError(err: Error): err is ApolloError;
// @public
export class LocalStateError extends Error {
constructor(message: string, options?: LocalStateError.Options);
static is(error: unknown): error is LocalStateError;
readonly path?: Array<string | number>;
}

// @public (undocumented)
export type NetworkError = Error | ServerParseError | ServerError | null;
export const PROTOCOL_ERRORS_SYMBOL: unique symbol;

// @public (undocumented)
type Path = ReadonlyArray<string | number>;
// @internal @deprecated
export function registerLinkError(error: ErrorLike): void;

// @public (undocumented)
export const PROTOCOL_ERRORS_SYMBOL: unique symbol;
export namespace ServerError {
// (undocumented)
export interface Options {
// (undocumented)
bodyText: string;
// (undocumented)
response: Response;
}
}

// @public (undocumented)
type ServerError = Error & {
// @public
export class ServerError extends Error {
constructor(message: string, options: ServerError.Options);
bodyText: string;
static is(error: unknown): error is ServerError;
response: Response;
result: Record<string, any> | string;
statusCode: number;
};
}

// @public (undocumented)
type ServerParseError = Error & {
// @public
export class ServerParseError extends Error {
// Warning: (ae-forgotten-export) The symbol "ServerParseErrorOptions" needs to be exported by the entry point index.d.ts
constructor(originalParseError: unknown, options: ServerParseErrorOptions);
bodyText: string;
static is(error: unknown): error is ServerParseError;
response: Response;
statusCode: number;
bodyText: string;
};
}

// Warning: (ae-forgotten-export) The symbol "DefaultContext" needs to be exported by the entry point index.d.ts
//
// @public (undocumented)
interface SingleExecutionResult<TData = Record<string, any>, TContext = DefaultContext, TExtensions = Record<string, any>> {
// (undocumented)
context?: TContext;
interface ServerParseErrorOptions {
// (undocumented)
data?: TData | null;
// (undocumented)
errors?: ReadonlyArray<GraphQLFormattedError>;
bodyText: string;
// (undocumented)
extensions?: TExtensions;
response: Response;
}

// @public (undocumented)
export function toErrorLike(error: unknown): ErrorLike;

// @public
export class UnconventionalError extends Error {
constructor(errorType: unknown);
static is(error: unknown): error is UnconventionalError;
}

// (No @packageDocumentation comment for this package)
Expand Down
109 changes: 109 additions & 0 deletions .api-reports/api-report-incremental.api.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
## API Report File for "@apollo/client"

> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
```ts

import type { DeepPartial } from '@apollo/client/utilities';
import type { DocumentNode } from 'graphql';
import type { FetchResult } from '@apollo/client';
import type { FormattedExecutionResult } from 'graphql';
import type { GraphQLFormattedError } from 'graphql';
import type { GraphQLRequest } from '@apollo/client';

// @public (undocumented)
namespace Defer20220824Handler {
// (undocumented)
type Chunk<TData extends Record<string, unknown>> = InitialResult<TData> | SubsequentResult<TData>;
// (undocumented)
type IncrementalDeferPayload<TData = Record<string, unknown>> = {
data?: TData | null | undefined;
errors?: ReadonlyArray<GraphQLFormattedError>;
extensions?: Record<string, unknown>;
path?: Incremental.Path;
label?: string;
};
// (undocumented)
type InitialResult<TData = Record<string, unknown>> = {
data?: TData | null | undefined;
errors?: ReadonlyArray<GraphQLFormattedError>;
extensions?: Record<string, unknown>;
hasNext: boolean;
};
// (undocumented)
type SubsequentResult<TData = Record<string, unknown>> = {
data?: TData | null | undefined;
errors?: ReadonlyArray<GraphQLFormattedError>;
extensions?: Record<string, unknown>;
hasNext: boolean;
incremental?: Array<IncrementalDeferPayload<TData>>;
};
}

// @public
class Defer20220824Handler implements Incremental.Handler<Defer20220824Handler.Chunk<any>> {
// (undocumented)
extractErrors(result: FetchResult<any>): GraphQLFormattedError[] | undefined;
// (undocumented)
isIncrementalResult(result: Record<string, any>): result is Defer20220824Handler.SubsequentResult | Defer20220824Handler.InitialResult;
// (undocumented)
prepareRequest(request: GraphQLRequest): GraphQLRequest;
// Warning: (ae-forgotten-export) The symbol "DeferRequest" needs to be exported by the entry point index.d.ts
//
// (undocumented)
startRequest<TData extends Record<string, unknown>>(_: {
query: DocumentNode;
}): DeferRequest<TData>;
}
export { Defer20220824Handler }
export { Defer20220824Handler as GraphQL17Alpha2Handler }

// @public (undocumented)
class DeferRequest<TData extends Record<string, unknown>> implements Incremental.IncrementalRequest<Defer20220824Handler.Chunk<TData>, TData> {
// (undocumented)
handle(cacheData: TData | DeepPartial<TData> | null | undefined, chunk: Defer20220824Handler.Chunk<TData>): FormattedExecutionResult<TData>;
// (undocumented)
hasNext: boolean;
}

// @public (undocumented)
export namespace Incremental {
// @internal @deprecated (undocumented)
export interface Handler<Chunk extends Record<string, unknown> = Record<string, unknown>> {
// (undocumented)
extractErrors: (result: FetchResult<any>) => readonly GraphQLFormattedError[] | undefined | void;
// (undocumented)
isIncrementalResult: (result: FetchResult<any>) => result is Chunk;
// (undocumented)
prepareRequest: (request: GraphQLRequest) => GraphQLRequest;
// (undocumented)
startRequest: <TData extends Record<string, unknown>>(request: {
query: DocumentNode;
}) => IncrementalRequest<Chunk, TData>;
}
// (undocumented)
export interface IncrementalRequest<Chunk extends Record<string, unknown>, TData> {
// (undocumented)
handle: (cacheData: TData | DeepPartial<TData> | undefined | null, chunk: Chunk) => FormattedExecutionResult<TData>;
// (undocumented)
hasNext: boolean;
}
// (undocumented)
export type Path = ReadonlyArray<string | number>;
}

// @public (undocumented)
export class NotImplementedHandler implements Incremental.Handler<never> {
// (undocumented)
extractErrors(): void;
// (undocumented)
isIncrementalResult(_: any): _ is never;
// (undocumented)
prepareRequest(request: GraphQLRequest): GraphQLRequest<Record<string, any>>;
// (undocumented)
startRequest: any;
}

// (No @packageDocumentation comment for this package)

```
Loading