Conversation
swarajpure
left a comment
There was a problem hiding this comment.
I guess it'd be better to have default value for method and responseType as well since most of the requests on the frontend will be GET and response type of most requests would be json only
What do you think @Akashdeep-Patra? 🤔
|
@swarajpure axios already has a default value for method i.e get, and i can put a json default for responseType? |
|
Hi @Akashdeep-Patra , I had a small request, There was a bad user experience observed when a user tries to perform send/receive operation multiple times due to declaring the value of receiver and currency type as null on close modal. @Kratika0907 @swarajpure I have requested @Akashdeep-Patra in the call to make this change and include in this PR. Thanks @Akashdeep-Patra for the quick fix |
|
|
||
| const closeModal = () => { | ||
| showModal((prev) => !prev); | ||
| setReceiver(''); |
There was a problem hiding this comment.
Thanks for the quick fix
utils/request/index.js
Outdated
| timeout: 1000, | ||
| }); | ||
|
|
||
| export const makeRequest = (obj) => { |
There was a problem hiding this comment.
proper naming obj can be renamed as requestConfig
There was a problem hiding this comment.
naming requestObject because it will also have other info i.e data, and config is a bit misleading

constants and utils package added, a wrapper for axios request added