Skip to content
This repository has been archived by the owner on Nov 11, 2023. It is now read-only.

Commit

Permalink
Import useMutate on generated components
Browse files Browse the repository at this point in the history
  • Loading branch information
fabien0102 committed May 17, 2019
1 parent 17bd22e commit ed78ff2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/scripts/import-open-api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,7 @@ const importOpenApi = async (
imports.push("Get", "GetProps", "useGet", "UseGetProps");
}
if (haveMutate) {
imports.push("Mutate", "MutateProps");
imports.push("Mutate", "MutateProps", "useMutate", "UseMutateProps");
}
if (havePoll) {
imports.push("Poll", "PollProps");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ exports[`scripts/import-open-api should parse correctly petstore-expanded.yaml 1
"/* Generated by restful-react */
import React from \\"react\\";
import { Get, GetProps, useGet, UseGetProps, Mutate, MutateProps } from \\"restful-react\\";
import { Get, GetProps, useGet, UseGetProps, Mutate, MutateProps, useMutate, UseMutateProps } from \\"restful-react\\";
export type Omit<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>;
Expand Down

0 comments on commit ed78ff2

Please sign in to comment.