Skip to content

Commit

Permalink
Type MutationResult.reset as an arrow function (#12027)
Browse files Browse the repository at this point in the history
Co-authored-by: Lenz Weber-Tronic <[email protected]>
Co-authored-by: Lenz Weber-Tronic <[email protected]>
  • Loading branch information
3 people authored Aug 27, 2024
1 parent 4210ab1 commit eb3e21b
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .api-reports/api-report-react.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1178,7 +1178,7 @@ export interface MutationResult<TData = any> {
data?: TData | null;
error?: ApolloError;
loading: boolean;
reset(): void;
reset: () => void;
}

// Warning: (ae-forgotten-export) The symbol "MutationBaseOptions" needs to be exported by the entry point index.d.ts
Expand Down
2 changes: 1 addition & 1 deletion .api-reports/api-report-react_components.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1059,7 +1059,7 @@ interface MutationResult<TData = any> {
data?: TData | null;
error?: ApolloError;
loading: boolean;
reset(): void;
reset: () => void;
}

// Warning: (ae-forgotten-export) The symbol "MutationBaseOptions" needs to be exported by the entry point index.d.ts
Expand Down
2 changes: 1 addition & 1 deletion .api-reports/api-report-react_hoc.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1052,7 +1052,7 @@ interface MutationResult<TData = any> {
data?: TData | null;
error?: ApolloError;
loading: boolean;
reset(): void;
reset: () => void;
}

// Warning: (ae-forgotten-export) The symbol "MutationBaseOptions" needs to be exported by the entry point index.d.ts
Expand Down
2 changes: 1 addition & 1 deletion .api-reports/api-report-react_hooks.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1120,7 +1120,7 @@ interface MutationResult<TData = any> {
data?: TData | null;
error?: ApolloError;
loading: boolean;
reset(): void;
reset: () => void;
}

// Warning: (ae-forgotten-export) The symbol "MutationBaseOptions" needs to be exported by the entry point index.d.ts
Expand Down
2 changes: 1 addition & 1 deletion .api-reports/api-report.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1629,7 +1629,7 @@ export interface MutationResult<TData = any> {
data?: TData | null;
error?: ApolloError;
loading: boolean;
reset(): void;
reset: () => void;
}

// Warning: (ae-forgotten-export) The symbol "MutationBaseOptions" needs to be exported by the entry point index.d.ts
Expand Down
5 changes: 5 additions & 0 deletions .changeset/modern-cows-tease.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@apollo/client": patch
---

Type `MutationResult.reset` as an arrow function
2 changes: 1 addition & 1 deletion src/react/types/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ export interface MutationResult<TData = any> {
/** {@inheritDoc @apollo/client!MutationResultDocumentation#client:member} */
client: ApolloClient<object>;
/** {@inheritDoc @apollo/client!MutationResultDocumentation#reset:member} */
reset(): void;
reset: () => void;
}

export declare type MutationFunction<
Expand Down

0 comments on commit eb3e21b

Please sign in to comment.