axios 1.8.1 → 1.8.3
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/CHANGELOG.md +25 -0
- package/README.md +8 -2
- package/dist/axios.js +3 -3
- 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 +3 -3
- package/dist/browser/axios.cjs.map +1 -1
- package/dist/esm/axios.js +3 -3
- 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 +4 -4
- package/dist/node/axios.cjs.map +1 -1
- package/index.d.cts +1 -0
- package/index.d.ts +1 -0
- package/lib/adapters/http.js +1 -1
- package/lib/env/data.js +1 -1
- package/lib/helpers/resolveConfig.js +1 -1
- package/package.json +1 -1
package/index.d.cts
CHANGED
@@ -376,6 +376,7 @@ declare namespace axios {
|
|
376
376
|
url?: string;
|
377
377
|
method?: Method | string;
|
378
378
|
baseURL?: string;
|
379
|
+
allowAbsoluteUrls?: boolean;
|
379
380
|
transformRequest?: AxiosRequestTransformer | AxiosRequestTransformer[];
|
380
381
|
transformResponse?: AxiosResponseTransformer | AxiosResponseTransformer[];
|
381
382
|
headers?: (RawAxiosRequestHeaders & MethodsHeaders) | AxiosHeaders;
|
package/index.d.ts
CHANGED
@@ -317,6 +317,7 @@ export interface AxiosRequestConfig<D = any> {
|
|
317
317
|
url?: string;
|
318
318
|
method?: Method | string;
|
319
319
|
baseURL?: string;
|
320
|
+
allowAbsoluteUrls?: boolean;
|
320
321
|
transformRequest?: AxiosRequestTransformer | AxiosRequestTransformer[];
|
321
322
|
transformResponse?: AxiosResponseTransformer | AxiosResponseTransformer[];
|
322
323
|
headers?: (RawAxiosRequestHeaders & MethodsHeaders) | AxiosHeaders;
|
package/lib/adapters/http.js
CHANGED
@@ -228,7 +228,7 @@ export default isHttpAdapterSupported && function httpAdapter(config) {
|
|
228
228
|
}
|
229
229
|
|
230
230
|
// Parse url
|
231
|
-
const fullPath = buildFullPath(config.baseURL, config.url);
|
231
|
+
const fullPath = buildFullPath(config.baseURL, config.url, config.allowAbsoluteUrls);
|
232
232
|
const parsed = new URL(fullPath, platform.hasBrowserEnv ? platform.origin : undefined);
|
233
233
|
const protocol = parsed.protocol || supportedProtocols[0];
|
234
234
|
|
package/lib/env/data.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
export const VERSION = "1.8.
|
1
|
+
export const VERSION = "1.8.3";
|
@@ -14,7 +14,7 @@ export default (config) => {
|
|
14
14
|
|
15
15
|
newConfig.headers = headers = AxiosHeaders.from(headers);
|
16
16
|
|
17
|
-
newConfig.url = buildURL(buildFullPath(newConfig.baseURL, newConfig.url), config.params, config.paramsSerializer);
|
17
|
+
newConfig.url = buildURL(buildFullPath(newConfig.baseURL, newConfig.url, newConfig.allowAbsoluteUrls), config.params, config.paramsSerializer);
|
18
18
|
|
19
19
|
// HTTP basic authentication
|
20
20
|
if (auth) {
|