Skip to content

Commit f8dab9d

Browse files
Version Packages (alpha) (#12962)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
1 parent 556e837 commit f8dab9d

File tree

4 files changed

+32
-3
lines changed

4 files changed

+32
-3
lines changed

.changeset/pre.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,15 @@
77
"@apollo/client-codemod-migrate-3-to-4": "1.0.2"
88
},
99
"changesets": [
10+
"big-flowers-move",
1011
"cold-kiwis-give",
1112
"flat-worms-notice",
1213
"funny-bats-hammer",
1314
"little-yaks-decide",
1415
"neat-lemons-shave",
1516
"olive-queens-fold",
1617
"perfect-crabs-smile",
18+
"popular-files-glow",
1719
"shaggy-islands-yell",
1820
"six-islands-drum",
1921
"unlucky-cooks-rhyme"

CHANGELOG.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,32 @@
11
# @apollo/client
22

3+
## 4.1.0-alpha.2
4+
5+
### Minor Changes
6+
7+
- [#12959](https://github.com/apollographql/apollo-client/pull/12959) [`556e837`](https://github.com/apollographql/apollo-client/commit/556e83781069d925a7e8f99e49023f6f858c6438) Thanks [@jerelmiller](https://github.com/jerelmiller)! - You can now provide a callback function as the `context` option on the `mutate` function returned by `useMutation`. The callback function is called with the value of the `context` option provided to the `useMutation` hook. This is useful if you'd like to merge the context object provided to the `useMutation` hook with a value provided to the `mutate` function.
8+
9+
```ts
10+
function MyComponent() {
11+
const [mutate, result] = useMutation(MUTATION, {
12+
context: { foo: true },
13+
});
14+
15+
async function runMutation() {
16+
await mutate({
17+
// sends context as { foo: true, bar: true }
18+
context: (hookContext) => ({ ...hookContext, bar: true }),
19+
});
20+
}
21+
22+
// ...
23+
}
24+
```
25+
26+
### Patch Changes
27+
28+
- [#12954](https://github.com/apollographql/apollo-client/pull/12954) [`1c82eaf`](https://github.com/apollographql/apollo-client/commit/1c82eafe4921a9e30128202623be6c5a3d4df803) Thanks [@jerelmiller](https://github.com/jerelmiller)! - Ensure an error is thrown when `@stream` is detected and an `incrementalDelivery` handler is not configured.
29+
330
## 4.1.0-alpha.1
431

532
### Minor Changes

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@apollo/client",
3-
"version": "4.1.0-alpha.1",
3+
"version": "4.1.0-alpha.2",
44
"description": "A fully-featured caching GraphQL client.",
55
"private": true,
66
"keywords": [

0 commit comments

Comments
 (0)