Skip to content

Commit

Permalink
Version Packages (alpha) (#10381)
Browse files Browse the repository at this point in the history
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
github-actions[bot] and github-actions[bot] authored Dec 21, 2022
1 parent 95eb228 commit b37e596
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 23 deletions.
2 changes: 1 addition & 1 deletion .changeset/pre.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
},
"changesets": [
"early-pens-retire",
"shiny-balloons-matter",
"sixty-trains-sniff",
"small-timers-shake"
]
}
41 changes: 22 additions & 19 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# @apollo/client

## 3.8.0-alpha.1

### Patch Changes

- [#10324](https://github.com/apollographql/apollo-client/pull/10324) [`95eb228be`](https://github.com/apollographql/apollo-client/commit/95eb228bedc193a520604e351d1c455bfbedef06) Thanks [@jerelmiller](https://github.com/jerelmiller)! - Add `@defer` support to `useSuspenseQuery`.

## 3.8.0-alpha.0

### Minor Changes
Expand Down Expand Up @@ -352,7 +358,7 @@ In upcoming v3.6.x and v3.7 (beta) releases, we will be completely overhauling o
const { resolver: defaultResolver } = getDefaultConfig.getDefaultValues();
exports.resolver = {
...defaultResolver,
sourceExts: [...defaultResolver.sourceExts, "cjs"],
sourceExts: [...defaultResolver.sourceExts, 'cjs'],
};
```

Expand Down Expand Up @@ -1059,11 +1065,11 @@ In upcoming v3.6.x and v3.7 (beta) releases, we will be completely overhauling o

- Internally, Apollo Client now avoids nested imports from the `graphql` package, importing everything from the top-level package instead. For example,
```ts
import { visit } from "graphql/language/visitor";
import { visit } from 'graphql/language/visitor';
```
is now just
```ts
import { visit } from "graphql";
import { visit } from 'graphql';
```
Since the `graphql` package uses `.mjs` modules, your bundler may need to be configured to recognize `.mjs` files as ECMAScript modules rather than CommonJS modules. <br/>
[@benjamn](https://github.com/benjamn) in [#7185](https://github.com/apollographql/apollo-client/pull/7185)
Expand Down Expand Up @@ -1434,8 +1440,7 @@ In upcoming v3.6.x and v3.7 (beta) releases, we will be completely overhauling o
- The `InMemoryCache` constructor should now be imported directly from `@apollo/client`, rather than from a separate package. The `apollo-cache-inmemory` package is no longer supported.

> The `@apollo/client/cache` entry point can be used to import `InMemoryCache` without importing other parts of the Apollo Client codebase. <br/>
> [@hwillson](https://github.com/hwillson) in [#5577](https://github.com/apollographql/apollo-client/pull/5577)
> The `@apollo/client/cache` entry point can be used to import `InMemoryCache` without importing other parts of the Apollo Client codebase. <br/> > [@hwillson](https://github.com/hwillson) in [#5577](https://github.com/apollographql/apollo-client/pull/5577)
- **[BREAKING]** `FragmentMatcher`, `HeuristicFragmentMatcher`, and `IntrospectionFragmentMatcher` have all been removed. We now recommend using `InMemoryCache`’s `possibleTypes` option instead. For more information see the [Defining `possibleTypes` manually](https://www.apollographql.com/docs/react/v3.0-beta/data/fragments/#defining-possibletypes-manually) section of the docs. <br/>
[@benjamn](https://github.com/benjamn) in [#5073](https://github.com/apollographql/apollo-client/pull/5073)
Expand Down Expand Up @@ -1481,7 +1486,7 @@ In upcoming v3.6.x and v3.7 (beta) releases, we will be completely overhauling o
fields: {
comments(comments: Reference[], { readField }) {
return comments.filter(
(comment) => idToRemove !== readField("id", comment)
(comment) => idToRemove !== readField('id', comment)
);
},
},
Expand All @@ -1495,12 +1500,12 @@ In upcoming v3.6.x and v3.7 (beta) releases, we will be completely overhauling o
- `InMemoryCache` provides a new API for storing client state that can be updated from anywhere:

```ts
import { makeVar } from "@apollo/client";
import { makeVar } from '@apollo/client';
const v = makeVar(123);
console.log(v()); // 123
console.log(v(v() + 1)); // 124
console.log(v()); // 124
v("asdf"); // TS type error
v('asdf'); // TS type error
```

These variables are _reactive_ in the sense that updating their values invalidates any previously cached query results that depended on the old values. <br/>
Expand Down Expand Up @@ -1552,7 +1557,7 @@ In upcoming v3.6.x and v3.7 (beta) releases, we will be completely overhauling o
- The contents of the `@apollo/react-hooks` package have been merged into `@apollo/client`, enabling the following all-in-one `import`:

```ts
import { ApolloClient, ApolloProvider, useQuery } from "@apollo/client";
import { ApolloClient, ApolloProvider, useQuery } from '@apollo/client';
```

[@hwillson](https://github.com/hwillson) in [#5357](https://github.com/apollographql/apollo-client/pull/5357)
Expand All @@ -1571,8 +1576,7 @@ In upcoming v3.6.x and v3.7 (beta) releases, we will be completely overhauling o
- **[BREAKING]** We are no longer exporting certain (intended to be) internal utilities. If you are depending on some of the lesser known exports from `apollo-cache`, `apollo-cache-inmemory`, or `apollo-utilities`, they may no longer be available from `@apollo/client`. <br/>
[@hwillson](https://github.com/hwillson) in [#5437](https://github.com/apollographql/apollo-client/pull/5437) and [#5514](https://github.com/apollographql/apollo-client/pull/5514)

> Utilities that were previously externally available through the `apollo-utilities` package are now only available by importing from `@apollo/client/utilities`. <br/>
> [@hwillson](https://github.com/hwillson) in [#5683](https://github.com/apollographql/apollo-client/pull/5683)
> Utilities that were previously externally available through the `apollo-utilities` package are now only available by importing from `@apollo/client/utilities`. <br/> > [@hwillson](https://github.com/hwillson) in [#5683](https://github.com/apollographql/apollo-client/pull/5683)
- Make sure all `graphql-tag` public exports are re-exported. <br/>
[@hwillson](https://github.com/hwillson) in [#5861](https://github.com/apollographql/apollo-client/pull/5861)
Expand Down Expand Up @@ -1728,13 +1732,13 @@ In upcoming v3.6.x and v3.7 (beta) releases, we will be completely overhauling o

```ts
export type FetchPolicy =
| "cache-first"
| "network-only"
| "cache-only"
| "no-cache"
| "standby";
| 'cache-first'
| 'network-only'
| 'cache-only'
| 'no-cache'
| 'standby';

export type WatchQueryFetchPolicy = FetchPolicy | "cache-and-network";
export type WatchQueryFetchPolicy = FetchPolicy | 'cache-and-network';
```

The exception thrown if you ignore the type error has also been improved to explain the motivation behind this restriction. <br/>
Expand Down Expand Up @@ -2339,8 +2343,7 @@ In upcoming v3.6.x and v3.7 (beta) releases, we will be completely overhauling o
Since the ^ operator only covers any minor version if the major version
is not 0 (since a major version of 0 is technically considered development by
semver 2), the current ^0.11.0 || ^14.0.0 graphql range doesn't cover
0.12._ or 0.13._. This fixes the `apollo-client@X has incorrect peer
dependency "graphql@^0.11.0 || ^14.0.0"` errors that people might have
0.12._ or 0.13._. This fixes the `apollo-client@X has incorrect peer dependency "graphql@^0.11.0 || ^14.0.0"` errors that people might have
seen using `graphql` 0.12.x or 0.13.x. <br/>
[@hwillson](https://github.com/hwillson) in [#3746](https://github.com/apollographql/apollo-client/pull/3746)
- Document `setVariables` internal API status. <br/>
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@apollo/client",
"version": "3.8.0-alpha.0",
"version": "3.8.0-alpha.1",
"description": "A fully-featured caching GraphQL client.",
"private": true,
"keywords": [
Expand Down

0 comments on commit b37e596

Please sign in to comment.