Jay
ef3711d1b3
feat: implement prettier and fix all issues ( #7385 )
...
* feat: implement prettier and fix all issues
* fix: failing tests
* fix: implement feedback from codel, ai etc
* chore: dont throw in trim function
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
* fix: incorrect fix
---------
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
2026-02-14 16:59:48 +02:00
Willian Agostini
569f028a58
fix: added a option to choose between legacy and the new request/response interceptor ordering
...
* test: add request interceptor tests for legacy and ordered execution
* feat: add legacy interceptor request/response ordering option
---------
Co-authored-by: Jay <jasonsaayman@gmail.com>
2026-01-30 08:12:04 +02:00
Copilot
d8233d9e8e
fix(types): restore AxiosError.cause type from unknown to Error ( #7327 )
...
* Initial plan
* fix(types): restore AxiosError.cause type from unknown to Error
Co-authored-by: jasonsaayman <4814473+jasonsaayman@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: jasonsaayman <4814473+jasonsaayman@users.noreply.github.com>
2026-01-12 16:20:00 +02:00
Tibor Pilz
8d1271b49f
fix(types): add handlers to AxiosInterceptorManager interface ( #5551 )
...
* fix(types): add handlers to AxiosInterceptorManager interface
* fix: runwhen should be optional
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* chore: make handlers optional
* chore: optional handlers
---------
Co-authored-by: Tibor Pilz <tibor.pilz@iu.org>
Co-authored-by: Jay <jasonsaayman@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-30 13:58:26 +02:00
Dmitriy Mozgovoy
d676df7722
feat(http): add HTTP2 support; ( #7150 )
2025-10-19 15:06:36 +03:00
Dmitriy Mozgovoy
b5f26b75bd
fix(types): fixed env config types; ( #7020 )
2025-09-12 16:33:42 +03:00
Dmitriy Mozgovoy
c959ff2901
feat(fetch): add fetch, Request, Response env config variables for the adapter; ( #7003 )
...
* feat(fetch): add fetch, Request, Response env config variables for the adapter;
* feat(fetch): fixed design issue for environments without fetch API globals;
2025-08-30 22:02:24 +03:00
Willian Agostini
7960d34ede
feat(types): extend AxiosResponse interface to include custom headers type ( #6782 )
2025-08-12 09:29:02 +02:00
khani
78b290c57c
feat(adapter): surface low‑level network error details; attach original error via cause ( #6982 )
...
* feat(adapter): surface low‑level network error details; attach original error via `cause`
Node http adapter:
- Promote low-level `err.code` to `AxiosError.code`, prefixing message (e.g. `ECONNREFUSED – …`)
- Keep original error on standard `Error.cause`
XHR adapter:
- Preserve browser `ProgressEvent` on `error.event`
- Use event message when available
Tests:
- Add Node ESM tests under `test/unit/adapters` to assert `code` and `cause` behavior
Types:
- Ensure `AxiosError.cause?: unknown` and `event?: ProgressEvent` are present
* fix(adapter): use fs instead of fs/promises for sync file read in tests to fix GitHub Actions
2025-07-30 09:57:27 +02:00
James Nail
8517aa16f8
fix(types): resolve type discrepancies between ESM and CJS TypeScript declaration files ( #6956 )
...
Co-authored-by: Jay <jasonsaayman@gmail.com>
2025-07-16 19:50:56 +02:00
Adrian Knapp
63f1fce233
feat(types): improved fetchOptions interface ( #6867 )
...
* feat(types): added js native interface for fetchOptions
* fix(types): adjusted to fetchOptions accept any value as the original version
---------
Co-authored-by: Jay <jasonsaayman@gmail.com>
2025-04-25 21:31:32 +02:00
FatahChan
e61a8934d8
fix(types): fix autocomplete for adapter config ( #6855 )
...
Co-authored-by: Dmitriy Mozgovoy <robotshara@gmail.com>
2025-04-19 18:54:33 +03:00
George Cheng
d1178cad4c
chore(types): move AxiosStatic#create to AxiosInstance#create ( #5096 )
...
* Add the bad test case.
* Fix and pass the test
* Update index.d.cts
---------
Co-authored-by: Jay <jasonsaayman@gmail.com>
2025-03-31 21:00:51 +02:00
StefanBRas
10fa70ef14
fix: add missing type for allowAbsoluteUrls ( #6818 )
...
* fix: add missing type for allowAbsoluteUrls
* fix: use semicolon in type files
---------
Co-authored-by: Jay <jasonsaayman@gmail.com>
2025-03-10 19:22:36 +02:00
Jay
c44d2f2316
Revert "fix(types): export CJS types from ESM ( #6218 )" ( #6729 )
...
This reverts commit c71811b00f .
2024-12-04 09:20:19 +02:00
Remco Haszing
c71811b00f
fix(types): export CJS types from ESM ( #6218 )
...
This prevents discrepancies between those from occurring.
Co-authored-by: Jay <jasonsaayman@gmail.com>
2024-11-19 10:39:59 +02:00
Amit Saini
82f94556e5
updated interceptor use type definition to remove interceptor options parameter from use method for response interceptors ( #5237 )
...
* updated interceptor use type definition to remove interceptor options parameter from use method for response interceptors
* incorporated type changes to index.d.cts
---------
Co-authored-by: Jay <jasonsaayman@gmail.com>
2024-10-31 16:01:37 +02:00
Dmitriy Mozgovoy
a3ff99b59d
feat(adapter): add fetch adapter; ( #6371 )
2024-04-28 22:33:49 +03:00
Zao Soula
a1938ff073
fix: fixed missed dispatchBeforeRedirect argument ( #5778 )
...
Co-authored-by: Dmitriy Mozgovoy <robotshara@gmail.com>
2024-01-25 00:57:06 +02:00
Dmitriy Mozgovoy
cff996779b
feat(withXSRFToken): added withXSRFToken option as a workaround to achieve the old withCredentials behavior; ( #6046 )
2023-11-14 15:38:25 +02:00
Dmitriy Mozgovoy
5aaff532a6
fix(dns): fixed lookup function decorator to work properly in node v20; ( #6011 )
2023-10-22 17:12:33 +03:00
Dmitriy Mozgovoy
a1c8ad008b
fix(types): fix AxiosHeaders types; ( #5931 )
2023-09-29 21:42:19 +03:00
Sean Sattler
9e6205630e
fix(types): removed duplicated code
...
Co-authored-by: Jay <jasonsaayman@gmail.com>
2023-08-30 20:29:27 +02:00
夜葬
ca73eb878d
feat: export getAdapter function ( #5324 )
2023-08-26 20:42:25 +03:00
Arthur Fiorette
726f1c8e00
feat(types): export AxiosHeaderValue type. ( #5525 )
2023-04-28 00:37:10 +03:00
Dmitriy Mozgovoy
2701911260
feat(dns): added support for a custom lookup function; ( #5339 )
2023-04-26 02:04:59 +03:00
Michael Di Prisco
6f360a2531
fix(types): added transport to RawAxiosRequestConfig ( #5445 )
2023-04-14 00:45:02 +03:00
Dmitriy Mozgovoy
a56c866120
fix(params): re-added the ability to set the function as paramsSerializer config; ( #5633 )
2023-04-05 19:44:36 +03:00
Dmitriy Mozgovoy
9915635c69
fix(headers): fixed & optimized clear method; ( #5507 )
2023-01-31 00:35:06 +02:00
Dmitriy Mozgovoy
5a3d0a3234
fix(types): fixed CommonRequestHeadersList & CommonResponseHeadersList types to be private in commonJS; ( #5503 )
2023-01-28 15:58:56 +02:00
Dmitriy Mozgovoy
580f1e8033
fix(types): fixed AxiosHeaders to handle spread syntax by making all methods non-enumerable; ( #5499 )
2023-01-26 16:01:06 +02:00
Dmitriy Mozgovoy
2a71f49bc6
fix(types): renamed RawAxiosRequestConfig back to AxiosRequestConfig; ( #5486 )
2023-01-23 01:09:18 +02:00
Dmitriy Mozgovoy
6486929f70
Fix AxiosRequestHeaders & AxiosHeaders types; ( #5482 )
2023-01-21 17:31:24 +02:00
Dmitriy Mozgovoy
08119634a2
fix(types): fixed AxiosRequestConfig header interface by refactoring it to RawAxiosRequestConfig; ( #5420 )
2023-01-06 02:02:08 +02:00
Dmitriy Mozgovoy
7a2f901f42
Fix/typescript tests ( #5375 )
...
* chore(ci): Add release-it script;
* chore(ci): add `release:no-npm` script to release the package without making an npm release;
* fix(test): fixed `d.ts` typings;
refactor(test): refactor typescript tests;
2022-12-14 22:49:49 +02:00
Dmitriy Mozgovoy
a6efeaf2d9
Change AxiosProgressEvent.event type to any; ( #5308 )
...
Co-authored-by: Jay <jasonsaayman@gmail.com>
2022-12-01 21:03:58 +02:00
Remco Haszing
abf954185a
fix: fix TypeScript type definitions for commonjs ( #5196 )
...
This is done by duplicating `index.d.ts` into `index.d.cts`, and
modifying it for CommonJS. The same was done for type tests.
Unfortunately I was unable to find a way to re-use types without
drastically changing the code base.
To test this, a minimum TypeScript version of 4.7 is needed, so it has
been updated. The old types still work with older TypeScript versions.
Co-authored-by: Jay <jasonsaayman@gmail.com>
2022-11-10 20:23:02 +02:00