useAxios Support custom ResponseType
See original GitHub issueClear and concise description of the problem
Now that axios supports custom responseType, I want useAxios to update
get<T = any, R = AxiosResponse<T>, D = any>(url: string, config?: AxiosRequestConfig<D>): Promise<R>;
delete<T = any, R = AxiosResponse<T>, D = any>(url: string, config?: AxiosRequestConfig<D>): Promise<R>;
Suggested solution
UseAxios<T, R,D>
Alternative
No response
Additional context
No response
Validations
- Follow our Code of Conduct
- Read the Contributing Guidelines.
- Read the docs.
- Check that there isn’t already an issue that request the same feature to avoid creating a duplicate.
Issue Analytics
- State:
- Created a year ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
How to use Axios with TypeScript when using response ...
Summary In a project I am migrating to TypeScript (TS), I have a response interceptor r => r.data. How do I inform TS...
Read more >React and TypeScript—which types for an Axios response?
thanks, so I should use axios.get<User> instead of useState<User>() ? If I try that, Typescript complains about useState() being undefined.
Read more >Request Config | Axios Docs
For Bearer tokens and such, use `Authorization` custom headers instead. auth: { username: 'janedoe', password: 's00pers3cret' }, // `responseType` indicates ...
Read more >Handle Blobs requests with Axios the right way - Medium
We have to create first our request: The most tricky part here is to change the responseType . We don't want to get ......
Read more >How to make HTTP requests with Axios - LogRocket Blog
Using axios.all to send multiple requests; Sending custom headers with ... Canceling requests; Popular Axios libraries; Browser support.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@Surof1n https://github.com/vueuse/vueuse/pull/2304
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.