@apollo/client 4.0.12 → 4.0.13

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,19 @@
1
1
  # @apollo/client
2
2
 
3
+ ## 4.0.13
4
+
5
+ ### Patch Changes
6
+
7
+ - [#13094](https://github.com/apollographql/apollo-client/pull/13094) [`9cbe2c2`](https://github.com/apollographql/apollo-client/commit/9cbe2c2dd2282ac861327d3c394578db7706df05) Thanks [@phryneas](https://github.com/phryneas)! - Ensure that `compact` and `mergeOptions` preserve symbol keys.
8
+
9
+ This fixes an issue where the change introduced in 4.0.11 via #13049 would not
10
+ be applied if `defaultOptions` for `watchQuery` were declared.
11
+
12
+ Please note that `compact` and `mergeOptions` are considered internal utilities
13
+ and they might have similar behavior changes in future releases.
14
+ Do not use them in your application code - a change like this is not considered
15
+ breaking and will not be announced as such.
16
+
3
17
  ## 4.0.12
4
18
 
5
19
  ### Patch Changes
@@ -14,7 +14,7 @@ function compact(...objects) {
14
14
  objects.forEach((obj) => {
15
15
  if (!obj)
16
16
  return;
17
- Object.keys(obj).forEach((key) => {
17
+ Reflect.ownKeys(obj).forEach((key) => {
18
18
  const value = obj[key];
19
19
  if (value !== void 0) {
20
20
  result[key] = value;
@@ -1 +1 @@
1
- {"version":3,"file":"compact.cjs","sources":["../../../../src/utilities/internal/compact.ts"],"sourcesContent":["import type { TupleToIntersection } from \"./types/TupleToIntersection.js\";\n\n/**\n * Merges the provided objects shallowly and removes\n * all properties with an `undefined` value\n *\n * @internal\n */\nexport function compact<TArgs extends any[]>(\n ...objects: TArgs\n): TupleToIntersection<TArgs> {\n const result = {} as TupleToIntersection<TArgs>;\n\n objects.forEach((obj) => {\n if (!obj) return;\n Object.keys(obj).forEach((key) => {\n const value = (obj as any)[key];\n if (value !== void 0) {\n result[key] = value;\n }\n });\n });\n\n return result;\n}\n"],"names":[],"mappings":";;AAQA,CAAA,CAAA,CAAA,C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;IAEF,CAAF,CAAA,CAAA,CAAA,CAAA,EAAS,CAAT,CAAA,CAAA,CAAA,CAAA,CAAe;AACf;"}
1
+ {"version":3,"file":"compact.cjs","sources":["../../../../src/utilities/internal/compact.ts"],"sourcesContent":["import type { TupleToIntersection } from \"./types/TupleToIntersection.js\";\n\n/**\n * Merges the provided objects shallowly and removes\n * all properties with an `undefined` value\n *\n * @internal\n */\nexport function compact<TArgs extends any[]>(\n ...objects: TArgs\n): TupleToIntersection<TArgs> {\n const result = {} as TupleToIntersection<TArgs>;\n\n objects.forEach((obj) => {\n if (!obj) return;\n Reflect.ownKeys(obj).forEach((key: keyof typeof obj) => {\n const value = obj[key];\n if (value !== void 0) {\n result[key] = value;\n }\n });\n });\n\n return result;\n}\n"],"names":[],"mappings":";;AAQA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAA,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA;;;;;;;;;AAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAgB,CAAhB,CAAA,CAAA,CAAA,CAAA,CAAA,CAAuB,CACrB,CADF,CAAA,CACK,CADL,CAAA,CAAA,CAAA,CAAA,CAAA,CACmB,EADnB;IAGE,CAAF,CAAA,CAAA,CAAA,EAAQ,CAAR,CAAA,CAAA,CAAA,CAAA,EAAA,EAAiB,CAAjB,CAAiD;IAE/C,CAAF,CAAA,CAAA,CAAA,CAAA,CAAA,CAAS,CAAC,CAAV,CAAA,CAAA,CAAA,CAAA,CAAA,CAAiB,CAAC,CAAC,CAAnB,CAAA,CAAsB,EAAE,CAAxB,EAAA;QACI,CAAJ,EAAA,CAAQ,CAAC,CAAT,CAAA,CAAY;YAAE,CAAd,CAAA,CAAA,CAAA,CAAA,CAAA;QACI,CAAJ,CAAA,CAAA,CAAA,CAAA,CAAA,CAAW,CAAC,CAAZ,CAAA,CAAA,CAAA,CAAA,CAAA,CAAmB,CAAC,CAApB,CAAA,CAAuB,CAAC,CAAC,CAAzB,CAAA,CAAA,CAAA,CAAA,CAAA,CAAgC,CAAC,CAAC,CAAlC,CAAA,CAAuD,EAAE,CAAzD,EAAA;YACM,CAAN,CAAA,CAAA,CAAA,EAAY,CAAZ,CAAA,CAAA,CAAA,EAAA,EAAoB,CAApB,CAAA,CAAuB,CAAC,CAAxB,CAAA,CAA2B,CAAC;YACtB,CAAN,EAAA,CAAU,CAAV,CAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAoB,CAApB,CAAA,CAAA,EAAyB,CAAC,EAAE;gBACpB,CAAR,CAAA,CAAA,CAAA,CAAA,CAAc,CAAC,CAAf,CAAA,CAAkB,EAAlB,EAAsB,CAAtB,CAAA,CAAA,CAAA,CAA2B;YACrB;QACF,CAAC,CAAC;IACJ,CAAC,CAAC;IAEF,CAAF,CAAA,CAAA,CAAA,CAAA,EAAS,CAAT,CAAA,CAAA,CAAA,CAAA,CAAe;AACf;"}
package/__cjs/version.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.build = exports.version = void 0;
4
- exports.version = "4.0.12";
4
+ exports.version = "4.0.13";
5
5
  exports.build = "cjs";
6
6
  //# sourceMappingURL=version.cjs.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@apollo/client",
3
- "version": "4.0.12",
3
+ "version": "4.0.13",
4
4
  "description": "A fully-featured caching GraphQL client.",
5
5
  "private": false,
6
6
  "keywords": [
@@ -11,7 +11,7 @@ export function compact(...objects) {
11
11
  objects.forEach((obj) => {
12
12
  if (!obj)
13
13
  return;
14
- Object.keys(obj).forEach((key) => {
14
+ Reflect.ownKeys(obj).forEach((key) => {
15
15
  const value = obj[key];
16
16
  if (value !== void 0) {
17
17
  result[key] = value;
@@ -1 +1 @@
1
- {"version":3,"file":"compact.js","sources":["../../../src/utilities/internal/compact.ts"],"sourcesContent":["import type { TupleToIntersection } from \"./types/TupleToIntersection.js\";\n\n/**\n * Merges the provided objects shallowly and removes\n * all properties with an `undefined` value\n *\n * @internal\n */\nexport function compact<TArgs extends any[]>(\n ...objects: TArgs\n): TupleToIntersection<TArgs> {\n const result = {} as TupleToIntersection<TArgs>;\n\n objects.forEach((obj) => {\n if (!obj) return;\n Object.keys(obj).forEach((key) => {\n const value = (obj as any)[key];\n if (value !== void 0) {\n result[key] = value;\n }\n });\n });\n\n return result;\n}\n"],"names":[],"mappings":";;;;;;;;AAQA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAgB,CAAhB,CAAA,CAAA,CAAA,CAAA,CAAA,CAAuB,CACrB,CADF,CAAA,CACK,CADL,CAAA,CAAA,CAAA,CAAA,CAAA,CACmB,EADnB;IAGE,CAAF,CAAA,CAAA,CAAA,EAAQ,CAAR,CAAA,CAAA,CAAA,CAAA,EAAA,EAAiB,CAAjB,CAAiD;IAE/C,CAAF,CAAA,CAAA,CAAA,CAAA,CAAA,CAAS,CAAC,CAAV,CAAA,CAAA,CAAA,CAAA,CAAA,CAAiB,CAAC,CAAC,CAAnB,CAAA,CAAsB,EAAE,CAAxB,EAAA;QACI,CAAJ,EAAA,CAAQ,CAAC,CAAT,CAAA,CAAY;YAAE,CAAd,CAAA,CAAA,CAAA,CAAA,CAAA;QACI,CAAJ,CAAA,CAAA,CAAA,CAAA,CAAU,CAAC,CAAX,CAAA,CAAA,CAAe,CAAC,CAAhB,CAAA,CAAmB,CAAC,CAAC,CAArB,CAAA,CAAA,CAAA,CAAA,CAAA,CAA4B,CAAC,CAAC,CAA9B,CAAA,CAAiC,EAAE,CAAnC,EAAA;YACM,CAAN,CAAA,CAAA,CAAA,EAAY,CAAZ,CAAA,CAAA,CAAA,EAAA,EAAqB,CAArB,CAAA,CAAgC,CAAC,CAAjC,CAAA,CAAoC,CAAC;YAC/B,CAAN,EAAA,CAAU,CAAV,CAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAoB,CAApB,CAAA,CAAA,EAAyB,CAAC,EAAE;gBACpB,CAAR,CAAA,CAAA,CAAA,CAAA,CAAc,CAAC,CAAf,CAAA,CAAkB,EAAlB,EAAsB,CAAtB,CAAA,CAAA,CAAA,CAA2B;YACrB;QACF,CAAC,CAAC;IACJ,CAAC,CAAC;IAEF,CAAF,CAAA,CAAA,CAAA,CAAA,EAAS,CAAT,CAAA,CAAA,CAAA,CAAA,CAAe;AACf;"}
1
+ {"version":3,"file":"compact.js","sources":["../../../src/utilities/internal/compact.ts"],"sourcesContent":["import type { TupleToIntersection } from \"./types/TupleToIntersection.js\";\n\n/**\n * Merges the provided objects shallowly and removes\n * all properties with an `undefined` value\n *\n * @internal\n */\nexport function compact<TArgs extends any[]>(\n ...objects: TArgs\n): TupleToIntersection<TArgs> {\n const result = {} as TupleToIntersection<TArgs>;\n\n objects.forEach((obj) => {\n if (!obj) return;\n Reflect.ownKeys(obj).forEach((key: keyof typeof obj) => {\n const value = obj[key];\n if (value !== void 0) {\n result[key] = value;\n }\n });\n });\n\n return result;\n}\n"],"names":[],"mappings":";;;;;;;;AAQA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,CAAA,EAAgB,CAAhB,CAAA,CAAA,CAAA,CAAA,CAAA,CAAuB,CACrB,CADF,CAAA,CACK,CADL,CAAA,CAAA,CAAA,CAAA,CAAA,CACmB,EADnB;IAGE,CAAF,CAAA,CAAA,CAAA,EAAQ,CAAR,CAAA,CAAA,CAAA,CAAA,EAAA,EAAiB,CAAjB,CAAiD;IAE/C,CAAF,CAAA,CAAA,CAAA,CAAA,CAAA,CAAS,CAAC,CAAV,CAAA,CAAA,CAAA,CAAA,CAAA,CAAiB,CAAC,CAAC,CAAnB,CAAA,CAAsB,EAAE,CAAxB,EAAA;QACI,CAAJ,EAAA,CAAQ,CAAC,CAAT,CAAA,CAAY;YAAE,CAAd,CAAA,CAAA,CAAA,CAAA,CAAA;QACI,CAAJ,CAAA,CAAA,CAAA,CAAA,CAAA,CAAW,CAAC,CAAZ,CAAA,CAAA,CAAA,CAAA,CAAA,CAAmB,CAAC,CAApB,CAAA,CAAuB,CAAC,CAAC,CAAzB,CAAA,CAAA,CAAA,CAAA,CAAA,CAAgC,CAAC,CAAC,CAAlC,CAAA,CAAuD,EAAE,CAAzD,EAAA;YACM,CAAN,CAAA,CAAA,CAAA,EAAY,CAAZ,CAAA,CAAA,CAAA,EAAA,EAAoB,CAApB,CAAA,CAAuB,CAAC,CAAxB,CAAA,CAA2B,CAAC;YACtB,CAAN,EAAA,CAAU,CAAV,CAAA,CAAA,CAAA,EAAA,CAAA,CAAA,EAAoB,CAApB,CAAA,CAAA,EAAyB,CAAC,EAAE;gBACpB,CAAR,CAAA,CAAA,CAAA,CAAA,CAAc,CAAC,CAAf,CAAA,CAAkB,EAAlB,EAAsB,CAAtB,CAAA,CAAA,CAAA,CAA2B;YACrB;QACF,CAAC,CAAC;IACJ,CAAC,CAAC;IAEF,CAAF,CAAA,CAAA,CAAA,CAAA,EAAS,CAAT,CAAA,CAAA,CAAA,CAAA,CAAe;AACf;"}
package/version.js CHANGED
@@ -1,3 +1,3 @@
1
- export const version = "4.0.12";
1
+ export const version = "4.0.13";
2
2
  export const build = "esm";
3
3
  //# sourceMappingURL=version.js.map