@swan-io/graphql-client
Advanced tools
Comparing version 0.2.1 to 0.2.2
@@ -1413,3 +1413,6 @@ 'use strict'; | ||
); | ||
return [commitMutation, data]; | ||
const reset = react.useCallback(() => { | ||
setData(boxed.AsyncData.NotAsked()); | ||
}, []); | ||
return [commitMutation, data, { reset }]; | ||
}; | ||
@@ -1416,0 +1419,0 @@ var mergeConnection = (previous, next, mode) => { |
@@ -10,3 +10,6 @@ import { AsyncData, Future, Result } from "@swan-io/boxed"; | ||
(variables: Variables, config?: MutationExtraConfig) => Future<Result<Data, ClientError>>, | ||
AsyncData<Result<Data, ClientError>> | ||
AsyncData<Result<Data, ClientError>>, | ||
{ | ||
reset: () => void; | ||
} | ||
]; | ||
@@ -13,0 +16,0 @@ export type MutationConfig<Data, Variables> = { |
{ | ||
"name": "@swan-io/graphql-client", | ||
"version": "0.2.1", | ||
"version": "0.2.2", | ||
"license": "MIT", | ||
@@ -5,0 +5,0 @@ "description": "A simple, typesafe GraphQL client for React", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
370480
3572