A Guide To Writing Clean API Calls Using Axios
TLDRAxios is a third-party library that lets you write clean API calls. It gives features such as interceptors, defaults, etc. It can be overkill for small apps. It bloats your production build size. It is not native to Javascript, unlike Fetch.
Table of contents
IntroductionPros and Cons of Using AxiosInstalling AxiosMaking separate Axios clientsUsing interceptors for clean redirectsExporting Axios ClientFolder structureWriting an API HandlerUsing the handlers in your web app3 Comments
Sort: