@apollo/client 3.5.4 → 3.5.5
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/apollo-client.cjs +73 -62
- package/apollo-client.cjs.map +1 -1
- package/apollo-client.min.cjs +1 -1
- package/cache/cache.cjs +15 -15
- package/cache/cache.cjs.map +1 -1
- package/cache/inmemory/helpers.js +1 -1
- package/cache/inmemory/helpers.js.map +1 -1
- package/cache/inmemory/key-extractor.js +2 -2
- package/cache/inmemory/key-extractor.js.map +1 -1
- package/cache/inmemory/policies.js +3 -3
- package/cache/inmemory/policies.js.map +1 -1
- package/cache/inmemory/readFromStore.js +3 -3
- package/cache/inmemory/readFromStore.js.map +1 -1
- package/cache/inmemory/writeToStore.js +6 -6
- package/cache/inmemory/writeToStore.js.map +1 -1
- package/core/ApolloClient.js +1 -1
- package/core/ApolloClient.js.map +1 -1
- package/core/LocalState.js +1 -1
- package/core/LocalState.js.map +1 -1
- package/core/ObservableQuery.js +2 -2
- package/core/ObservableQuery.js.map +1 -1
- package/core/QueryManager.js +1 -1
- package/core/QueryManager.js.map +1 -1
- package/core/core.cjs +10 -10
- package/core/core.cjs.map +1 -1
- package/errors/errors.cjs +2 -2
- package/errors/errors.cjs.map +1 -1
- package/errors/index.js +2 -2
- package/errors/index.js.map +1 -1
- package/invariantErrorCodes.js +25 -25
- package/link/batch/batch.cjs +1 -1
- package/link/batch/batch.cjs.map +1 -1
- package/link/batch/batching.js +1 -1
- package/link/batch/batching.js.map +1 -1
- package/link/batch-http/batch-http.cjs +1 -1
- package/link/batch-http/batch-http.cjs.map +1 -1
- package/link/batch-http/batchHttpLink.js +2 -2
- package/link/batch-http/batchHttpLink.js.map +1 -1
- package/link/http/createHttpLink.js +2 -2
- package/link/http/createHttpLink.js.map +1 -1
- package/link/http/http.cjs +24 -13
- package/link/http/http.cjs.map +1 -1
- package/link/http/index.d.ts +1 -1
- package/link/http/index.d.ts.map +1 -1
- package/link/http/index.js +1 -1
- package/link/http/index.js.map +1 -1
- package/link/http/parseAndCheckHttpResponse.js +3 -3
- package/link/http/parseAndCheckHttpResponse.js.map +1 -1
- package/link/http/rewriteURIForGET.js +1 -1
- package/link/http/rewriteURIForGET.js.map +1 -1
- package/link/http/selectHttpOptionsAndBody.d.ts +5 -1
- package/link/http/selectHttpOptionsAndBody.d.ts.map +1 -1
- package/link/http/selectHttpOptionsAndBody.js +19 -8
- package/link/http/selectHttpOptionsAndBody.js.map +1 -1
- package/link/http/serializeFetchParameter.js +1 -1
- package/link/http/serializeFetchParameter.js.map +1 -1
- package/link/utils/utils.cjs +1 -1
- package/link/utils/utils.cjs.map +1 -1
- package/link/utils/validateOperation.js +1 -1
- package/link/utils/validateOperation.js.map +1 -1
- package/main.cjs +4 -4
- package/package.json +9 -9
- package/react/components/components.cjs +3 -3
- package/react/context/context.cjs +3 -3
- package/react/hoc/hoc.cjs +9 -9
- package/react/hoc/hoc.cjs.map +1 -1
- package/react/hoc/mutation-hoc.js +2 -2
- package/react/hoc/mutation-hoc.js.map +1 -1
- package/react/hoc/query-hoc.js +1 -1
- package/react/hoc/query-hoc.js.map +1 -1
- package/react/hoc/subscription-hoc.js +1 -1
- package/react/hoc/subscription-hoc.js.map +1 -1
- package/react/hoc/withApollo.js +1 -1
- package/react/hoc/withApollo.js.map +1 -1
- package/react/parser/index.js +7 -7
- package/react/parser/index.js.map +1 -1
- package/react/parser/parser.cjs +7 -7
- package/react/parser/parser.cjs.map +1 -1
- package/react/react.cjs +2 -2
- package/react/ssr/ssr.cjs +3 -3
- package/testing/core/core.cjs +2 -2
- package/testing/core/core.cjs.map +1 -1
- package/testing/core/mocking/mockFetch.js +1 -1
- package/testing/core/mocking/mockFetch.js.map +1 -1
- package/testing/core/mocking/mockLink.js +2 -2
- package/testing/core/mocking/mockLink.js.map +1 -1
- package/testing/core/observableToPromise.js +1 -1
- package/testing/core/observableToPromise.js.map +1 -1
- package/testing/testing.cjs +5 -5
- package/utilities/common/makeUniqueId.js +1 -1
- package/utilities/common/makeUniqueId.js.map +1 -1
- package/utilities/graphql/directives.js +4 -4
- package/utilities/graphql/directives.js.map +1 -1
- package/utilities/graphql/fragments.js +3 -3
- package/utilities/graphql/fragments.js.map +1 -1
- package/utilities/graphql/getFromAST.js +2 -2
- package/utilities/graphql/getFromAST.js.map +1 -1
- package/utilities/graphql/storeUtils.js +5 -5
- package/utilities/graphql/storeUtils.js.map +1 -1
- package/utilities/utilities.cjs +15 -15
- package/utilities/utilities.cjs.map +1 -1
- package/version.js +1 -1
package/core/core.cjs
CHANGED
|
@@ -15,7 +15,7 @@ var utils = require('../link/utils');
|
|
|
15
15
|
var tsInvariant = require('ts-invariant');
|
|
16
16
|
var graphqlTag = require('graphql-tag');
|
|
17
17
|
|
|
18
|
-
var version = '3.5.
|
|
18
|
+
var version = '3.5.5';
|
|
19
19
|
|
|
20
20
|
exports.NetworkStatus = void 0;
|
|
21
21
|
(function (NetworkStatus) {
|
|
@@ -191,7 +191,7 @@ var ObservableQuery = (function (_super) {
|
|
|
191
191
|
var queryDef = utilities.getQueryDefinition(this.options.query);
|
|
192
192
|
var vars = queryDef.variableDefinitions;
|
|
193
193
|
if (!vars || !vars.some(function (v) { return v.variable.name.value === "variables"; })) {
|
|
194
|
-
__DEV__ && globals.invariant.warn("Called refetch("
|
|
194
|
+
__DEV__ && globals.invariant.warn("Called refetch(".concat(JSON.stringify(variables), ") for query ").concat(((_a = queryDef.name) === null || _a === void 0 ? void 0 : _a.value) || JSON.stringify(queryDef), ", which does not declare a $variables variable.\nDid you mean to call refetch(variables) instead of refetch({ variables })?"));
|
|
195
195
|
}
|
|
196
196
|
}
|
|
197
197
|
if (variables && !equality.equal(this.options.variables, variables)) {
|
|
@@ -454,7 +454,7 @@ function defaultSubscriptionObserverErrorCallback(error) {
|
|
|
454
454
|
}
|
|
455
455
|
function logMissingFieldErrors(missing) {
|
|
456
456
|
if (__DEV__ && missing) {
|
|
457
|
-
__DEV__ && globals.invariant.debug("Missing cache result fields: "
|
|
457
|
+
__DEV__ && globals.invariant.debug("Missing cache result fields: ".concat(JSON.stringify(missing)), missing);
|
|
458
458
|
}
|
|
459
459
|
}
|
|
460
460
|
function applyNextFetchPolicy(options) {
|
|
@@ -635,7 +635,7 @@ var LocalState = (function () {
|
|
|
635
635
|
}
|
|
636
636
|
else {
|
|
637
637
|
fragment = fragmentMap[selection.name.value];
|
|
638
|
-
__DEV__ ? globals.invariant(fragment, "No fragment named "
|
|
638
|
+
__DEV__ ? globals.invariant(fragment, "No fragment named ".concat(selection.name.value)) : globals.invariant(fragment, 9);
|
|
639
639
|
}
|
|
640
640
|
if (fragment && fragment.typeCondition) {
|
|
641
641
|
typeCondition = fragment.typeCondition.name.value;
|
|
@@ -1426,7 +1426,7 @@ var QueryManager = (function () {
|
|
|
1426
1426
|
if (__DEV__ && queryNamesAndDocs.size) {
|
|
1427
1427
|
queryNamesAndDocs.forEach(function (included, nameOrDoc) {
|
|
1428
1428
|
if (!included) {
|
|
1429
|
-
__DEV__ && globals.invariant.warn("Unknown query "
|
|
1429
|
+
__DEV__ && globals.invariant.warn("Unknown query ".concat(typeof nameOrDoc === "string" ? "named " : "").concat(JSON.stringify(nameOrDoc, null, 2), " requested in refetchQueries options.include array"));
|
|
1430
1430
|
}
|
|
1431
1431
|
});
|
|
1432
1432
|
}
|
|
@@ -2017,7 +2017,7 @@ var ApolloClient = (function () {
|
|
|
2017
2017
|
result.queries = queries;
|
|
2018
2018
|
result.results = results;
|
|
2019
2019
|
result.catch(function (error) {
|
|
2020
|
-
__DEV__ && globals.invariant.debug("In client.refetchQueries, Promise.all promise rejected with error "
|
|
2020
|
+
__DEV__ && globals.invariant.debug("In client.refetchQueries, Promise.all promise rejected with error ".concat(error));
|
|
2021
2021
|
});
|
|
2022
2022
|
return result;
|
|
2023
2023
|
};
|
|
@@ -2076,10 +2076,10 @@ exports.ApolloClient = ApolloClient;
|
|
|
2076
2076
|
exports.ObservableQuery = ObservableQuery;
|
|
2077
2077
|
exports.applyNextFetchPolicy = applyNextFetchPolicy;
|
|
2078
2078
|
exports.mergeOptions = mergeOptions;
|
|
2079
|
-
|
|
2079
|
+
for (var k in core) {
|
|
2080
2080
|
if (k !== 'default' && !exports.hasOwnProperty(k)) exports[k] = core[k];
|
|
2081
|
-
}
|
|
2082
|
-
|
|
2081
|
+
}
|
|
2082
|
+
for (var k in http) {
|
|
2083
2083
|
if (k !== 'default' && !exports.hasOwnProperty(k)) exports[k] = http[k];
|
|
2084
|
-
}
|
|
2084
|
+
}
|
|
2085
2085
|
//# sourceMappingURL=core.cjs.map
|