Axios is a promise-based HTTP client for both browser and Node.js. The current stable version is 1.0.0. It provides a simple API for making XMLHttpRequests in the browser and http requests in Node.js, with features like interceptors, automatic JSON transformation, and request cancellation. Axios is widely used due to its ease of use, support for older browsers (IE11), and TypeScript types. It follows semver and has a consistent release cadence with minor updates every few months.
npm install extrareqp2No compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows a GET request with params, error handling with axios.isAxiosError, and async/await usage.
Use import axios from 'axios' instead of require('axios'). In TypeScript, use esModuleInterop.Use `httpAdapter` for Node.js or `xhrAdapter` for browser instead of `adapter`.
Set `responseType: 'text'` explicitly if expecting non-JSON responses, or use `transformResponse`.
Refer to axios documentation for compatibility; extrareqp2 may have unknown breaking changes.
Use AbortController from the platform (browser or Node.js 16+) to cancel requests.
For JSON, ensure data is an object and Axios will set Content-Type: application/json automatically. For form data, use URLSearchParams or FormData.
Check if error.response exists before accessing data: if (error.response) { console.log(error.response.data); }Run `npm install axios` and ensure the import path is correct. For CDN, use script tag.
Check browser console for CORS errors, ensure endpoint is reachable, and configure CORS on server.
Use `const axios = require('axios')` in Node.js CJS or enable esModuleInterop in tsconfig.No dependency data recorded yet.