An Axios adapter for uni-app that bridges Axios HTTP client with uni-app's `uni.request` and `uni.uploadFile` APIs, enabling developers to use Axios-style request configuration and interceptors within uni-app projects. Current version 0.1.4 is stable with low release cadence. Key differentiators: seamless integration with Axios ecosystem (interceptors, CancelToken), support for GET/POST and file uploads via `uni.uploadFile`, and compatibility with Axios' cancellation pattern.
npm install axios-adapter-uniappNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to import, configure, and use axios-adapter-uniapp for GET and file upload requests in a uni-app environment.
Use only GET and POST methods. For file uploads, ensure config includes `filePath` and `name` or `files` array.
Handle cancellation in catch block with `axios.isCancel()`; be aware that the request might still be sent.
Use `params` instead of `data` for GET requests to ensure compatibility with standard Axios.
Refer to uni-app `uni.uploadFile` documentation for correct file object structure (`{ name, uri }`).Run `npm install axios-adapter-uniapp` and ensure the path in import statement is correct.
Use `import axiosAdapterUniapp from 'axios-adapter-uniapp'` and then `adapter: axiosAdapterUniapp`.
Ensure axios is installed (`npm install axios`) and imported correctly.
Check baseURL, ensure network permissions are granted, and use valid URLs.