axios 1.6.7 → 1.7.0-beta.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.
Potentially problematic release.
This version of axios might be problematic. Click here for more details.
- package/CHANGELOG.md +31 -0
- package/README.md +35 -16
- package/dist/axios.js +1271 -580
- package/dist/axios.js.map +1 -1
- package/dist/axios.min.js +1 -1
- package/dist/axios.min.js.map +1 -1
- package/dist/browser/axios.cjs +651 -302
- package/dist/browser/axios.cjs.map +1 -1
- package/dist/esm/axios.js +651 -302
- package/dist/esm/axios.js.map +1 -1
- package/dist/esm/axios.min.js +1 -1
- package/dist/esm/axios.min.js.map +1 -1
- package/dist/node/axios.cjs +562 -243
- package/dist/node/axios.cjs.map +1 -1
- package/index.d.cts +5 -2
- package/index.d.ts +5 -2
- package/lib/adapters/adapters.js +3 -1
- package/lib/adapters/fetch.js +197 -0
- package/lib/adapters/http.js +1 -1
- package/lib/adapters/xhr.js +31 -101
- package/lib/core/AxiosHeaders.js +4 -0
- package/lib/core/mergeConfig.js +1 -1
- package/lib/defaults/index.js +7 -2
- package/lib/env/data.js +1 -1
- package/lib/helpers/AxiosTransformStream.js +9 -8
- package/lib/helpers/composeSignals.js +46 -0
- package/lib/helpers/progressEventReducer.js +32 -0
- package/lib/helpers/resolveConfig.js +57 -0
- package/lib/helpers/throttle.js +5 -3
- package/lib/helpers/trackStream.js +56 -0
- package/lib/platform/common/utils.js +4 -1
- package/lib/utils.js +7 -2
- package/package.json +26 -25
package/CHANGELOG.md
CHANGED
@@ -1,5 +1,36 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
# [1.7.0-beta.0](https://github.com/axios/axios/compare/v1.6.8...v1.7.0-beta.0) (2024-04-28)
|
4
|
+
|
5
|
+
|
6
|
+
### Features
|
7
|
+
|
8
|
+
* **adapter:** add fetch adapter; ([#6371](https://github.com/axios/axios/issues/6371)) ([a3ff99b](https://github.com/axios/axios/commit/a3ff99b59d8ec2ab5dd049e68c043617a4072e42))
|
9
|
+
|
10
|
+
### Contributors to this release
|
11
|
+
|
12
|
+
- <img src="https://avatars.githubusercontent.com/u/12586868?v=4&s=18" alt="avatar" width="18"/> [Dmitriy Mozgovoy](https://github.com/DigitalBrainJS "+1015/-127 (#6371 )")
|
13
|
+
- <img src="https://avatars.githubusercontent.com/u/4814473?v=4&s=18" alt="avatar" width="18"/> [Jay](https://github.com/jasonsaayman "+30/-14 ()")
|
14
|
+
|
15
|
+
## [1.6.8](https://github.com/axios/axios/compare/v1.6.7...v1.6.8) (2024-03-15)
|
16
|
+
|
17
|
+
|
18
|
+
### Bug Fixes
|
19
|
+
|
20
|
+
* **AxiosHeaders:** fix AxiosHeaders conversion to an object during config merging ([#6243](https://github.com/axios/axios/issues/6243)) ([2656612](https://github.com/axios/axios/commit/2656612bc10fe2757e9832b708ed773ab340b5cb))
|
21
|
+
* **import:** use named export for EventEmitter; ([7320430](https://github.com/axios/axios/commit/7320430aef2e1ba2b89488a0eaf42681165498b1))
|
22
|
+
* **vulnerability:** update follow-redirects to 1.15.6 ([#6300](https://github.com/axios/axios/issues/6300)) ([8786e0f](https://github.com/axios/axios/commit/8786e0ff55a8c68d4ca989801ad26df924042e27))
|
23
|
+
|
24
|
+
### Contributors to this release
|
25
|
+
|
26
|
+
- <img src="https://avatars.githubusercontent.com/u/4814473?v=4&s=18" alt="avatar" width="18"/> [Jay](https://github.com/jasonsaayman "+4572/-3446 (#6238 )")
|
27
|
+
- <img src="https://avatars.githubusercontent.com/u/12586868?v=4&s=18" alt="avatar" width="18"/> [Dmitriy Mozgovoy](https://github.com/DigitalBrainJS "+30/-0 (#6231 )")
|
28
|
+
- <img src="https://avatars.githubusercontent.com/u/68230846?v=4&s=18" alt="avatar" width="18"/> [Mitchell](https://github.com/Creaous "+9/-9 (#6300 )")
|
29
|
+
- <img src="https://avatars.githubusercontent.com/u/53797821?v=4&s=18" alt="avatar" width="18"/> [Emmanuel](https://github.com/mannoeu "+2/-2 (#6196 )")
|
30
|
+
- <img src="https://avatars.githubusercontent.com/u/44109284?v=4&s=18" alt="avatar" width="18"/> [Lucas Keller](https://github.com/ljkeller "+3/-0 (#6194 )")
|
31
|
+
- <img src="https://avatars.githubusercontent.com/u/72791488?v=4&s=18" alt="avatar" width="18"/> [Aditya Mogili](https://github.com/ADITYA-176 "+1/-1 ()")
|
32
|
+
- <img src="https://avatars.githubusercontent.com/u/46135319?v=4&s=18" alt="avatar" width="18"/> [Miroslav Petrov](https://github.com/petrovmiroslav "+1/-1 (#6243 )")
|
33
|
+
|
3
34
|
## [1.6.7](https://github.com/axios/axios/compare/v1.6.6...v1.6.7) (2024-01-25)
|
4
35
|
|
5
36
|
|
package/README.md
CHANGED
@@ -25,20 +25,36 @@
|
|
25
25
|
<br><br>
|
26
26
|
</h3>
|
27
27
|
|
28
|
-
<
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
</
|
28
|
+
<table border="0">
|
29
|
+
<td align="center">
|
30
|
+
<a href="https://stytch.com?utm_source=oss-sponsorship&utm_medium=paid_sponsorship&utm_content=logo&utm_campaign=axios-http">
|
31
|
+
<picture>
|
32
|
+
<source width="200px" media="(prefers-color-scheme: dark)" srcset="https://github.com/axios/axios/assets/4814473/538d715a-13c7-4668-ae7d-37a4548423f4">
|
33
|
+
<source width="200px" media="(prefers-color-scheme: light)" srcset="https://github.com/axios/axios/assets/4814473/b6a9a7bc-9fb1-4b9b-909f-1b4bee1fd142">
|
34
|
+
<img width="200px" src="https://github.com/axios/axios/assets/4814473/b6a9a7bc-9fb1-4b9b-909f-1b4bee1fd142" />
|
35
|
+
</picture>
|
36
|
+
</a>
|
37
|
+
<p align="center">API-first authentication, authorization, and fraud prevention</p>
|
38
|
+
<p align="center">
|
39
|
+
<a href="https://stytch.com?utm_source=oss-sponsorship&utm_medium=paid_sponsorship&utm_content=website-link&utm_campaign=axios-http"><b>Website</b></a> •
|
40
|
+
<a href="https://stytch.com/docs?utm_source=oss-sponsorship&utm_medium=paid_sponsorship&utm_content=docs-link&utm_campaign=axios-http"><b>Documentation</b></a> • <a href="https://github.com/stytchauth/stytch-node?utm_source=oss-sponsorship&utm_medium=paid_sponsorship&utm_content=node-sdk&utm_campaign=axios-http"><b>Node.js Backend SDK</b></a>
|
41
|
+
</p>
|
42
|
+
</td>
|
43
|
+
<td align="center">
|
44
|
+
<a href="https://stytch.com?utm_source=oss-sponsorship&utm_medium=paid_sponsorship&utm_content=logo&utm_campaign=axios-http">
|
45
|
+
<picture>
|
46
|
+
<source width="200px" media="(prefers-color-scheme: dark)" srcset="https://github.com/axios/axios/assets/4814473/79f572f3-9d57-488d-80cc-58d674bb98d8">
|
47
|
+
<source width="200px" media="(prefers-color-scheme: light)" srcset="https://github.com/axios/axios/assets/4814473/18b51893-c4b4-4557-b263-74c2b3de84ab">
|
48
|
+
<img width="200px" src="https://github.com/axios/axios/assets/4814473/18b51893-c4b4-4557-b263-74c2b3de84ab" />
|
49
|
+
</picture>
|
50
|
+
</a>
|
51
|
+
<p align="center">Drag-and-drop authentication, authorization, and identity management</p>
|
52
|
+
<p align="center">
|
53
|
+
<a href="https://www.descope.com/?utm_source=axios&utm_medium=referral&utm_campaign=axios-oss-sponsorship"><b>Website</b></a> •
|
54
|
+
<a href="https://docs.descope.com/?utm_source=axios&utm_medium=referral&utm_campaign=axios-oss-sponsorship"><b>Documentation</b></a> • <a href="https://www.descope.com/community?utm_source=axios&utm_medium=referral&utm_campaign=axios-oss-sponsorship"><b>Community</b></a>
|
55
|
+
</p>
|
56
|
+
</td>
|
57
|
+
</table>
|
42
58
|
|
43
59
|
|
44
60
|
<br><br>
|
@@ -199,13 +215,13 @@ const axios = require('axios/dist/browser/axios.cjs'); // browser commonJS bundl
|
|
199
215
|
Using jsDelivr CDN (ES5 UMD browser module):
|
200
216
|
|
201
217
|
```html
|
202
|
-
<script src="https://cdn.jsdelivr.net/npm/axios@1.
|
218
|
+
<script src="https://cdn.jsdelivr.net/npm/axios@1.6.7/dist/axios.min.js"></script>
|
203
219
|
```
|
204
220
|
|
205
221
|
Using unpkg CDN:
|
206
222
|
|
207
223
|
```html
|
208
|
-
<script src="https://unpkg.com/axios@1.
|
224
|
+
<script src="https://unpkg.com/axios@1.6.7/dist/axios.min.js"></script>
|
209
225
|
```
|
210
226
|
|
211
227
|
## Example
|
@@ -487,6 +503,9 @@ These are the available config options for making requests. Only the `url` is re
|
|
487
503
|
|
488
504
|
// `responseEncoding` indicates encoding to use for decoding responses (Node.js only)
|
489
505
|
// Note: Ignored for `responseType` of 'stream' or client-side requests
|
506
|
+
// options are: 'ascii', 'ASCII', 'ansi', 'ANSI', 'binary', 'BINARY', 'base64', 'BASE64', 'base64url',
|
507
|
+
// 'BASE64URL', 'hex', 'HEX', 'latin1', 'LATIN1', 'ucs-2', 'UCS-2', 'ucs2', 'UCS2', 'utf-8', 'UTF-8',
|
508
|
+
// 'utf8', 'UTF8', 'utf16le', 'UTF16LE'
|
490
509
|
responseEncoding: 'utf8', // default
|
491
510
|
|
492
511
|
// `xsrfCookieName` is the name of the cookie to use as a value for xsrf token
|