@apollo/client 3.6.0-rc.1 → 3.6.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/apollo-client.cjs +7 -4
- package/apollo-client.cjs.map +1 -1
- package/apollo-client.min.cjs +1 -1
- package/core/core.cjs +1 -1
- package/core/core.cjs.map +1 -1
- package/invariantErrorCodes.js +1 -1
- package/package.json +17 -17
- package/react/hooks/hooks.cjs +6 -3
- package/react/hooks/hooks.cjs.map +1 -1
- package/react/hooks/useMutation.d.ts.map +1 -1
- package/react/hooks/useMutation.js +6 -3
- package/react/hooks/useMutation.js.map +1 -1
- package/version.js +1 -1
package/apollo-client.cjs
CHANGED
|
@@ -1298,7 +1298,7 @@ var concat = ApolloLink.concat;
|
|
|
1298
1298
|
|
|
1299
1299
|
var execute = ApolloLink.execute;
|
|
1300
1300
|
|
|
1301
|
-
var version = '3.6.0
|
|
1301
|
+
var version = '3.6.0';
|
|
1302
1302
|
|
|
1303
1303
|
var hasOwnProperty$3 = Object.prototype.hasOwnProperty;
|
|
1304
1304
|
function parseAndCheckHttpResponse(operations) {
|
|
@@ -6543,9 +6543,12 @@ function useMutation(mutation, options) {
|
|
|
6543
6543
|
var reset = React.useCallback(function () {
|
|
6544
6544
|
setResult({ called: false, loading: false, client: client });
|
|
6545
6545
|
}, []);
|
|
6546
|
-
React.useEffect(function () {
|
|
6547
|
-
ref.current.isMounted =
|
|
6548
|
-
|
|
6546
|
+
React.useEffect(function () {
|
|
6547
|
+
ref.current.isMounted = true;
|
|
6548
|
+
return function () {
|
|
6549
|
+
ref.current.isMounted = false;
|
|
6550
|
+
};
|
|
6551
|
+
}, []);
|
|
6549
6552
|
return [execute, tslib.__assign({ reset: reset }, result)];
|
|
6550
6553
|
}
|
|
6551
6554
|
|