Skip to content

Commit cceb7b1

Browse files
chore(release): v1.8.0 (#6795)
Co-authored-by: jasonsaayman <[email protected]>
1 parent 23a25af commit cceb7b1

17 files changed

Lines changed: 153 additions & 47 deletions

CHANGELOG.md

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,55 @@
11
# Changelog
22

3+
# [1.8.0](https://github.com/axios/axios/compare/v1.7.9...v1.8.0) (2025-02-25)
4+
5+
6+
### Bug Fixes
7+
8+
* **examples:** application crashed when navigating examples in browser ([#5938](https://github.com/axios/axios/issues/5938)) ([1260ded](https://github.com/axios/axios/commit/1260ded634ec101dd5ed05d3b70f8e8f899dba6c))
9+
* missing word in SUPPORT_QUESTION.yml ([#6757](https://github.com/axios/axios/issues/6757)) ([1f890b1](https://github.com/axios/axios/commit/1f890b13f2c25a016f3c84ae78efb769f244133e))
10+
* **utils:** replace getRandomValues with crypto module ([#6788](https://github.com/axios/axios/issues/6788)) ([23a25af](https://github.com/axios/axios/commit/23a25af0688d1db2c396deb09229d2271cc24f6c))
11+
12+
13+
### Features
14+
15+
* Add config for ignoring absolute URLs ([#5902](https://github.com/axios/axios/issues/5902)) ([#6192](https://github.com/axios/axios/issues/6192)) ([32c7bcc](https://github.com/axios/axios/commit/32c7bcc0f233285ba27dec73a4b1e81fb7a219b3))
16+
17+
18+
### Reverts
19+
20+
* Revert "chore: expose fromDataToStream to be consumable (#6731)" (#6732) ([1317261](https://github.com/axios/axios/commit/1317261125e9c419fe9f126867f64d28f9c1efda)), closes [#6731](https://github.com/axios/axios/issues/6731) [#6732](https://github.com/axios/axios/issues/6732)
21+
22+
23+
### BREAKING CHANGES
24+
25+
* code relying on the above will now combine the URLs instead of prefer request URL
26+
27+
* feat: add config option for allowing absolute URLs
28+
29+
* fix: add default value for allowAbsoluteUrls in buildFullPath
30+
31+
* fix: typo in flow control when setting allowAbsoluteUrls
32+
33+
### Contributors to this release
34+
35+
- <img src="https://avatars.githubusercontent.com/u/7661715?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Michael Toscano](https://github.com/GethosTheWalrus "+42/-8 (#6192 )")
36+
- <img src="https://avatars.githubusercontent.com/u/22686401?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Willian Agostini](https://github.com/WillianAgostini "+26/-3 (#6788 #6777 )")
37+
- <img src="https://avatars.githubusercontent.com/u/72578270?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Naron](https://github.com/naronchen "+27/-0 (#5901 )")
38+
- <img src="https://avatars.githubusercontent.com/u/47430686?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [shravan || श्रvan](https://github.com/shravan20 "+7/-3 (#6116 )")
39+
- <img src="https://avatars.githubusercontent.com/u/145078271?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Justin Dhillon](https://github.com/justindhillon "+0/-7 (#6312 )")
40+
- <img src="https://avatars.githubusercontent.com/u/30925732?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [yionr](https://github.com/yionr "+5/-1 (#6129 )")
41+
- <img src="https://avatars.githubusercontent.com/u/534166?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Shin&#x27;ya Ueoka](https://github.com/ueokande "+3/-3 (#5935 )")
42+
- <img src="https://avatars.githubusercontent.com/u/33569?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Dan Dascalescu](https://github.com/dandv "+3/-3 (#5908 #6757 )")
43+
- <img src="https://avatars.githubusercontent.com/u/16476523?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Nitin Ramnani](https://github.com/NitinRamnani "+2/-2 (#5938 )")
44+
- <img src="https://avatars.githubusercontent.com/u/152275799?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Shay Molcho](https://github.com/shaymolcho "+2/-2 (#6770 )")
45+
- <img src="https://avatars.githubusercontent.com/u/4814473?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Jay](https://github.com/jasonsaayman "+0/-3 (#6732 )")
46+
- fancy45daddy
47+
- <img src="https://avatars.githubusercontent.com/u/127725897?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Habip Akyol](https://github.com/habipakyol "+1/-1 (#6030 )")
48+
- <img src="https://avatars.githubusercontent.com/u/54869395?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Bailey Lissington](https://github.com/llamington "+1/-1 (#6771 )")
49+
- <img src="https://avatars.githubusercontent.com/u/14969290?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Bernardo da Eira Duarte](https://github.com/bernardoduarte "+1/-1 (#6480 )")
50+
- <img src="https://avatars.githubusercontent.com/u/117800149?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Shivam Batham](https://github.com/Shivam-Batham "+1/-1 (#5949 )")
51+
- <img src="https://avatars.githubusercontent.com/u/67861627?v&#x3D;4&amp;s&#x3D;18" alt="avatar" width="18"/> [Lipin Kariappa](https://github.com/lipinnnnn "+1/-1 (#5936 )")
52+
353
## [1.7.9](https://github.com/axios/axios/compare/v1.7.8...v1.7.9) (2024-12-04)
454

555

bower.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "axios",
33
"main": "./dist/axios.js",
4-
"version": "1.7.9",
4+
"version": "1.8.0",
55
"homepage": "https://axios-http.com",
66
"authors": [
77
"Matt Zabriskie"

dist/axios.js

Lines changed: 25 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/axios.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/axios.min.js

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/axios.min.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/browser/axios.cjs

Lines changed: 23 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
1-
// Axios v1.7.9 Copyright (c) 2024 Matt Zabriskie and contributors
1+
/*! Axios v1.8.0 Copyright (c) 2025 Matt Zabriskie and contributors */
22
'use strict';
33

4+
var crypto = require('crypto');
5+
6+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
7+
8+
var crypto__default = /*#__PURE__*/_interopDefaultLegacy(crypto);
9+
410
function bind(fn, thisArg) {
511
return function wrap() {
612
return fn.apply(thisArg, arguments);
@@ -620,8 +626,10 @@ const ALPHABET = {
620626
const generateString = (size = 16, alphabet = ALPHABET.ALPHA_DIGIT) => {
621627
let str = '';
622628
const {length} = alphabet;
623-
while (size--) {
624-
str += alphabet[Math.random() * length|0];
629+
const randomValues = new Uint32Array(size);
630+
crypto__default["default"].randomFillSync(randomValues);
631+
for (let i = 0; i < size; i++) {
632+
str += alphabet[randomValues[i] % length];
625633
}
626634

627635
return str;
@@ -2248,8 +2256,9 @@ function combineURLs(baseURL, relativeURL) {
22482256
*
22492257
* @returns {string} The combined full path
22502258
*/
2251-
function buildFullPath(baseURL, requestedURL) {
2252-
if (baseURL && !isAbsoluteURL(requestedURL)) {
2259+
function buildFullPath(baseURL, requestedURL, allowAbsoluteUrls) {
2260+
let isRelativeUrl = !isAbsoluteURL(requestedURL);
2261+
if (baseURL && isRelativeUrl || allowAbsoluteUrls == false) {
22532262
return combineURLs(baseURL, requestedURL);
22542263
}
22552264
return requestedURL;
@@ -3089,7 +3098,7 @@ function dispatchRequest(config) {
30893098
});
30903099
}
30913100

3092-
const VERSION = "1.7.9";
3101+
const VERSION = "1.8.0";
30933102

30943103
const validators$1 = {};
30953104

@@ -3274,6 +3283,13 @@ class Axios {
32743283
}
32753284
}
32763285

3286+
// Set config.allowAbsoluteUrls
3287+
if (config.allowAbsoluteUrls !== undefined) ; else if (this.defaults.allowAbsoluteUrls !== undefined) {
3288+
config.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls;
3289+
} else {
3290+
config.allowAbsoluteUrls = true;
3291+
}
3292+
32773293
validator.assertOptions(config, {
32783294
baseUrl: validators.spelling('baseURL'),
32793295
withXsrfToken: validators.spelling('withXSRFToken')
@@ -3369,7 +3385,7 @@ class Axios {
33693385

33703386
getUri(config) {
33713387
config = mergeConfig(this.defaults, config);
3372-
const fullPath = buildFullPath(config.baseURL, config.url);
3388+
const fullPath = buildFullPath(config.baseURL, config.url, config.allowAbsoluteUrls);
33733389
return buildURL(fullPath, config.params, config.paramsSerializer);
33743390
}
33753391
}

dist/browser/axios.cjs.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/esm/axios.js

Lines changed: 19 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/esm/axios.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)