axios 1.13.6 → 1.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +26 -1
- package/dist/axios.js +91 -100
- package/dist/axios.js.map +1 -1
- package/dist/axios.min.js +2 -2
- package/dist/axios.min.js.map +1 -1
- package/dist/browser/axios.cjs +70 -84
- package/dist/browser/axios.cjs.map +1 -1
- package/dist/esm/axios.js +99 -116
- package/dist/esm/axios.js.map +1 -1
- package/dist/esm/axios.min.js +2 -2
- package/dist/esm/axios.min.js.map +1 -1
- package/dist/node/axios.cjs +1421 -2367
- package/dist/node/axios.cjs.map +1 -1
- package/lib/adapters/fetch.js +5 -1
- package/lib/adapters/http.js +5 -2
- package/lib/core/Axios.js +0 -2
- package/lib/core/AxiosHeaders.js +3 -1
- package/lib/env/data.js +1 -1
- package/lib/helpers/buildURL.js +2 -2
- package/package.json +93 -132
package/README.md
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
<h3 align="center"> 💎 Platinum sponsors <br> </h3> <table align="center"><tr><td align="center" width="50%"> <a href="https://thanks.dev/?utm_source=axios&utm_medium=sponsorlist&utm_campaign=sponsorship" style="padding: 10px; display: inline-block" target="_blank"> <img width="90px" height="90px" src="https://axios-http.com/assets/sponsors/opencollective/ed51c2ee8f1b70aa3484d6dd678652134079a036.png" alt="THANKS.DEV"/> </a> <p align="center" title="We're passionate about making open source sustainable. Scan your dependancy tree to better understand which open source projects need funding the most. Maintainers can also register their projects to become eligible for funding.">We're passionate about making open source sustainable. Scan your dependancy tree to better understand which open source projects need funding the...</p> <p align="center"> <a href="https://thanks.dev/?utm_source=axios&utm_medium=readme_sponsorlist&utm_campaign=sponsorship" target="_blank"><b>thanks.dev</b></a> </p>
|
|
2
|
+
</td><td align="center" width="50%"> <a href="https://opencollective.com/axios/contribute" target="_blank" >💜 Become a sponsor</a>
|
|
3
|
+
</td></tr></table>
|
|
1
4
|
<h3 align="center"> 🥇 Gold sponsors <br> </h3> <table align="center" width="100%"><tr width="33.333333333333336%"><td align="center" width="33.333333333333336%"> <a href="https://www.principal.com/about-us?utm_source=axios&utm_medium=sponsorlist&utm_campaign=sponsorship" style="padding: 10px; display: inline-block" target="_blank"> <img width="133px" height="43px" src="https://axios-http.com/assets/sponsors/principal.svg" alt="Principal Financial Group"/> </a> <p align="center" title="We’re bound by one common purpose: to give you the financial tools, resources and information you need to live your best life.">We’re bound by one common purpose: to give you the financial tools, resources and information you ne...</p> <p align="center"> <a href="https://www.principal.com/about-us?utm_source=axios&utm_medium=readme_sponsorlist&utm_campaign=sponsorship" target="_blank"><b>www.principal.com</b></a> </p>
|
|
2
5
|
</td><td align="center" width="33.333333333333336%"> <a href="https://twicsy.com/buy-instagram-followers?utm_source=axios&utm_medium=sponsorlist&utm_campaign=sponsorship" style="padding: 10px; display: inline-block" target="_blank"> <img width="85px" height="70px" src="https://axios-http.com/assets/sponsors/opencollective/dfa9670ad5e66eea17315332453c7f4e3a3b5905.png" alt="Buy Instagram Followers Twicsy"/> </a> <p align="center" title="Buy real Instagram followers from Twicsy starting at only $2.97. Twicsy has been voted the best site to buy followers from the likes of US Magazine.">Buy real Instagram followers from Twicsy starting at only $2.97. Twicsy has been voted the best site...</p> <p align="center"> <a href="https://twicsy.com/buy-instagram-followers?utm_source=axios&utm_medium=readme_sponsorlist&utm_campaign=sponsorship" target="_blank"><b>twicsy.com</b></a> </p>
|
|
3
6
|
</td><td align="center" width="33.333333333333336%"> <a href="https://www.descope.com/?utm_source=axios&utm_medium=referral&utm_campaign=axios-oss-sponsorship" style="padding: 10px; display: inline-block" target="_blank"> <picture> <source width="200px" height="52px" media="(prefers-color-scheme: dark)" srcset="https://axios-http.com/assets/sponsors/descope_white.png"> <img width="200px" height="52px" src="https://axios-http.com/assets/sponsors/descope.png" alt="Descope"/> </picture> </a> <p align="center" title="Hi, we're Descope! We are building something in the authentication space for app developers and can’t wait to place it in your hands.">Hi, we're Descope! We are building something in the authentication space for app developers and...</p> <p align="center"> <a href="https://www.descope.com/?utm_source=axios&utm_medium=referral&utm_campaign=axios-oss-sponsorship" target="_blank"><b>Website</b></a> | <a href="https://docs.descope.com/?utm_source=axios&utm_medium=referral&utm_campaign=axios-oss-sponsorship" target="_blank"><b>Docs</b></a> | <a href="https://www.descope.com/community?utm_source=axios&utm_medium=referral&utm_campaign=axios-oss-sponsorship" target="_blank"><b>Community</b></a> </p>
|
|
@@ -497,6 +500,23 @@ These are the available config options for making requests. Only the `url` is re
|
|
|
497
500
|
// `undefined` (default) - set XSRF header only for the same origin requests
|
|
498
501
|
withXSRFToken: boolean | undefined | ((config: InternalAxiosRequestConfig) => boolean | undefined),
|
|
499
502
|
|
|
503
|
+
// `withXSRFToken` controls whether Axios reads the XSRF cookie and sets the XSRF header.
|
|
504
|
+
// - `undefined` (default): the XSRF header is set only for same-origin requests.
|
|
505
|
+
// - `true`: attempt to set the XSRF header for all requests (including cross-origin).
|
|
506
|
+
// - `false`: never set the XSRF header.
|
|
507
|
+
// - function: a callback that receives the request `config` and returns `true`,
|
|
508
|
+
// `false`, or `undefined` to decide per-request behavior.
|
|
509
|
+
//
|
|
510
|
+
// Note about `withCredentials`: `withCredentials` controls whether cross-site
|
|
511
|
+
// requests include credentials (cookies and HTTP auth). In older Axios versions,
|
|
512
|
+
// setting `withCredentials: true` implicitly caused Axios to set the XSRF header
|
|
513
|
+
// for cross-origin requests. Newer Axios separates these concerns: to allow the
|
|
514
|
+
// XSRF header to be sent for cross-origin requests you should set both
|
|
515
|
+
// `withCredentials: true` and `withXSRFToken: true`.
|
|
516
|
+
//
|
|
517
|
+
// Example:
|
|
518
|
+
// axios.get('/user', { withCredentials: true, withXSRFToken: true });
|
|
519
|
+
|
|
500
520
|
// `onUploadProgress` allows handling of progress events for uploads
|
|
501
521
|
// browser & node.js
|
|
502
522
|
onUploadProgress: function ({loaded, total, progress, bytes, estimated, rate, upload = true}) {
|
|
@@ -607,7 +627,12 @@ These are the available config options for making requests. Only the `url` is re
|
|
|
607
627
|
transitional: {
|
|
608
628
|
// silent JSON parsing mode
|
|
609
629
|
// `true` - ignore JSON parsing errors and set response.data to null if parsing failed (old behaviour)
|
|
610
|
-
// `false` - throw SyntaxError if JSON parsing failed
|
|
630
|
+
// `false` - throw SyntaxError if JSON parsing failed
|
|
631
|
+
// Important: this option only takes effect when `responseType` is explicitly set to 'json'.
|
|
632
|
+
// When `responseType` is omitted (defaults to no value), axios uses `forcedJSONParsing`
|
|
633
|
+
// to attempt JSON parsing, but will silently return the raw string on failure regardless
|
|
634
|
+
// of this setting. To have invalid JSON throw errors, use:
|
|
635
|
+
// { responseType: 'json', transitional: { silentJSONParsing: false } }
|
|
611
636
|
silentJSONParsing: true, // default value for the current Axios version
|
|
612
637
|
|
|
613
638
|
// try to parse the response string as JSON even if `responseType` is not 'json'
|