@graphcommerce/graphql 3.1.3 → 3.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Change Log
2
2
 
3
+ ## 3.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#1492](https://github.com/graphcommerce-org/graphcommerce/pull/1492) [`bed806ddd`](https://github.com/graphcommerce-org/graphcommerce/commit/bed806dddd7e025806a69798ef9587aa165d392f) Thanks [@mikekeehnen](https://github.com/mikekeehnen)! - Removed useExtractCustomerErrors hook and implemented error handling via HttpLink Error
8
+
3
9
  ## 3.1.3
4
10
 
5
11
  ### Patch Changes
package/apollo.ts CHANGED
@@ -1,6 +1,15 @@
1
+ import { ApolloCache, NormalizedCacheObject } from '@apollo/client'
2
+
1
3
  export { cloneDeep, mergeDeep } from '@apollo/client/utilities'
2
4
 
3
5
  export * from '@apollo/client'
4
6
  export * from '@apollo/client/link/schema'
5
7
  export * from '@apollo/client/link/context'
8
+ export * from '@apollo/client/link/error'
9
+
6
10
  export { getOperationName } from '@apollo/client/utilities'
11
+
12
+ export type ClientContext = {
13
+ cache: ApolloCache<NormalizedCacheObject>
14
+ headers?: Record<string, string>
15
+ }
@@ -27,6 +27,8 @@ export function createCacheReviver(
27
27
  if (typeof window !== 'undefined') {
28
28
  try {
29
29
  const { cache } = client
30
+
31
+ // todo https://github.com/apollographql/apollo-cache-persist/tree/master/examples/react-native/src/utils/persistence
30
32
  persistor = new CachePersistor({
31
33
  cache,
32
34
  storage: new LocalStorageWrapper(window.localStorage),
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@graphcommerce/graphql",
3
3
  "homepage": "https://www.graphcommerce.org/",
4
4
  "repository": "github:graphcommerce-org/graphcommerce",
5
- "version": "3.1.3",
5
+ "version": "3.2.0",
6
6
  "sideEffects": false,
7
7
  "main": "index.ts",
8
8
  "prettier": "@graphcommerce/prettier-config-pwa",