Skip to content

Commit

Permalink
explicit typing in api.mustache template
Browse files Browse the repository at this point in the history
Co-authored-by: Jason Schapiro <[email protected]>
Co-authored-by: Nicolas Favaro <[email protected]>
  • Loading branch information
3 people committed Feb 10, 2021
1 parent b735965 commit eb61410
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{{>licenseInfo}}
import { AxiosRequestConfig } from 'axios';
import { AxiosRequestConfig, Method } from 'axios';
import { axios } from '../axios.config';
{{#hasFormParams}}
import { stringify } from 'qs';
Expand Down Expand Up @@ -38,7 +38,7 @@ export class {{classname}}Resource {
{{/hasFormParams}}
let reqConfig = {
...axiosConfig,
method: '{{httpMethod}}',
method: '{{httpMethod}}' as Method,
url: reqPath{{#hasQueryParams}},
params: query{{/hasQueryParams}}{{#bodyParam}},
data: {{paramName}}{{/bodyParam}}{{#hasFormParams}},
Expand Down

0 comments on commit eb61410

Please sign in to comment.