2
0
mirror of https://github.com/tenrok/axios.git synced 2026-05-15 11:59:42 +03:00
Commit Graph

1259 Commits

Author SHA1 Message Date
Dmitriy Mozgovoy bdf493cf8b Axios ES2017 (#4787)
* Added AxiosHeaders class;

* Fixed README.md href;

* Fixed a potential bug with headers normalization;

* Fixed a potential bug with headers normalization;
Refactored accessor building routine;
Refactored default transforms;
Removed `normalizeHeaderName` helper;

* Added `Content-Length` accessor;
Added missed `has` accessor to TS types;

* Added `AxiosTransformStream` class;
Added progress capturing ability for node.js environment;
Added `maxRate` option to limit the data rate in node.js environment;
Refactored event handled by `onUploadProgress` && `onDownloadProgress` listeners in browser environment;
Added progress & data rate tests for the http adapter;
Added response stream aborting test;
Added a manual progress capture test for the browser;
Updated TS types;
Added TS tests;
Refactored request abort logic for the http adapter;
Added ability to abort the response stream;

* Remove `stream/promises` & `timers/promises` modules usage in tests;

* Use `abortcontroller-polyfill`;

* Fixed AxiosTransformStream dead-lock in legacy node versions;
Fixed CancelError emitting in streams;

* Reworked AxiosTransformStream internal logic to optimize memory consumption;
Added throwing an error if the request stream was silently destroying (without error) Refers to #3966;

* Treat the destruction of the request stream as a cancellation of the request;
Fixed tests;

* Emit `progress` event in the next tick;

* Initial refactoring;

* Refactored Mocha tests to use ESM;

* Refactored Karma tests to use rollup preprocessor & ESM;
Replaced grunt with gulp;
Improved dev scripts;
Added Babel for rollup build;

* Added default commonjs package export for Node build;
Added automatic contributors list generator for package.json;

Co-authored-by: Jay <jasonsaayman@gmail.com>
2022-06-18 11:19:27 +02:00
dependabot[bot] 1db715dd3b chore(deps): bump actions/setup-node from 2 to 3 (#4798)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2 to 3.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-06-18 11:15:53 +02:00
dependabot[bot] 68723fc389 chore(deps): bump actions/stale from 3 to 5 (#4797)
Bumps [actions/stale](https://github.com/actions/stale) from 3 to 5.
- [Release notes](https://github.com/actions/stale/releases)
- [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/stale/compare/v3...v5)

---
updated-dependencies:
- dependency-name: actions/stale
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Jay <jasonsaayman@gmail.com>
2022-06-18 11:13:19 +02:00
dependabot[bot] de7f4c6c39 chore(deps): bump actions/checkout from 2 to 3 (#4796)
Bumps [actions/checkout](https://github.com/actions/checkout) from 2 to 3.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-06-18 11:11:11 +02:00
Naveen 6ac313a01e chore(deps): Included dependency review (#4771)
> Dependency Review GitHub Action in your repository to enforce dependency
> reviews on your pull requests.
> The action scans for vulnerable versions of dependencies introduced by package version
> changes in pull requests,
> and warns you about the associated security vulnerabilities.
> This gives you better visibility of what's changing in a pull request,
> and helps prevent vulnerabilities being added to your repository.

https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/about-dependency-review#dependency-review-enforcement
Signed-off-by: naveen <172697+naveensrinivasan@users.noreply.github.com>

Co-authored-by: Jay <jasonsaayman@gmail.com>
2022-06-18 11:07:56 +02:00
Naveen 7fac8ef19b chore: Included githubactions in the dependabot config (#4770)
This should help with keeping the GitHub actions updated on new releases. This will also help with keeping it secure.

Dependabot helps in keeping the supply chain secure https://docs.github.com/en/code-security/dependabot

GitHub actions up to date https://docs.github.com/en/code-security/dependabot/working-with-dependabot/keeping-your-actions-up-to-date-with-dependabot

https://github.com/ossf/scorecard/blob/main/docs/checks.md#dependency-update-tool
Signed-off-by: naveen <172697+naveensrinivasan@users.noreply.github.com>

Co-authored-by: Jay <jasonsaayman@gmail.com>
2022-06-18 11:05:40 +02:00
visortelle 5ba3f787c4 Fix - Request ignores false, 0 and empty string as body values (#4785)
Co-authored-by: Jay <jasonsaayman@gmail.com>
2022-06-14 21:56:17 +02:00
Pavlos e518c5da1b update security.md (#4784)
+ points to axios page instead of bounty calculator
+ improved copy
2022-06-14 20:44:31 +02:00
Jay 9e5145e714 fixed(ci): removed wrkflow permissions that are wrong 2022-06-02 21:38:47 +02:00
Jay 21a12de13e fix: merge conflict 2022-06-02 21:20:16 +02:00
Jay 7ec84f817f chore(GitHub Actions): rename master to main, added protections 2022-06-02 21:12:48 +02:00
neilnaveen ef6064c83b chore: Set permissions for GitHub actions (#4765)
Restrict the GitHub token permissions only to the required ones; this way, even if the attackers will succeed in compromising your workflow, they won’t be able to do much.

- Included permissions for the action. https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions

https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions

https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs

[Keeping your GitHub Actions and workflows secure Part 1: Preventing pwn requests](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/)

Signed-off-by: neilnaveen <42328488+neilnaveen@users.noreply.github.com>

Co-authored-by: Jay <jasonsaayman@gmail.com>
2022-06-02 21:09:29 +02:00
dependabot[bot] e42f35da7f Bump eventsource from 1.1.0 to 1.1.1 (#4764)
Bumps [eventsource](https://github.com/EventSource/eventsource) from 1.1.0 to 1.1.1.
- [Release notes](https://github.com/EventSource/eventsource/releases)
- [Changelog](https://github.com/EventSource/eventsource/blob/master/HISTORY.md)
- [Commits](https://github.com/EventSource/eventsource/compare/v1.1.0...v1.1.1)

---
updated-dependencies:
- dependency-name: eventsource
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Jay <jasonsaayman@gmail.com>
2022-06-02 21:01:30 +02:00
Jay 5db829d118 docs(adapters/http) 2022-06-02 20:57:16 +02:00
Jay 8a92772d16 docs(axios.js) 2022-06-02 20:56:53 +02:00
Jay 31fbee888f docs(cancel/CancelToken) 2022-06-02 20:56:32 +02:00
Jay a009842af9 docs(cancel/CanceledError) 2022-06-02 20:56:09 +02:00
Jay b80c7d3844 docs(core/Axios) 2022-06-02 20:55:27 +02:00
Jay c4c30b22d6 docs(core/AxiosError) 2022-06-02 20:54:47 +02:00
Jay fb8efb9a70 docs(core/InterceptorManager) 2022-06-02 20:54:24 +02:00
Jay 81c0b3568f docs(core/buildFullPath) 2022-06-02 20:53:57 +02:00
Jay 4f4c1d3be9 docs(core/dispatchRequest) 2022-06-02 20:53:31 +02:00
Jay 722640aeda docs(core/mergeConfig) 2022-06-02 20:53:07 +02:00
Jay 6e0aff9407 docs(core/settle) 2022-06-02 20:52:44 +02:00
Jay e9bd1626ff docs(core/transformData) 2022-06-02 20:52:22 +02:00
Jay 0148e4563d docs(defaults/index) 2022-06-02 20:52:04 +02:00
Jay e8dd5cb1ed docs(helpers/AxiosURLSearchParams) 2022-06-02 20:51:32 +02:00
Jay 6f06e25f53 docs(helpers/buildURL) 2022-06-02 20:51:03 +02:00
Jay 18e563d7f8 docs(helpers/combineURLs) 2022-06-02 20:50:41 +02:00
Jay 714daab1e7 docs(helpers/deprecatedMethod) 2022-06-02 20:50:16 +02:00
Jay ff2f0b4bd7 docs(helpers/formDataToJSON) 2022-06-02 20:49:51 +02:00
Jay a0808db951 docs(helpers/fromDataURI) 2022-06-02 20:49:21 +02:00
Jay 10c20daa2b docs(helpers/isAbsoluteURL) 2022-06-02 20:48:55 +02:00
Jay 910a920c55 docs(helpers/isAxiosError) 2022-06-02 20:48:22 +02:00
Jay 0556288a96 docs(helpers/parseHeaders) 2022-06-02 20:47:56 +02:00
Jay 5e2ffa2209 chore(helpers/spread): added docs for spread functions 2022-06-02 20:46:44 +02:00
Jay ba3e593807 chore(helpers/toFormData): added docs for to form data functions 2022-06-02 20:46:05 +02:00
Jay 34b71f0a1c chore(helpers/validator): added docs for validator function 2022-06-02 20:45:27 +02:00
Jay 74f59eac88 chore(Utils): added docs for utils functions 2022-06-02 20:44:27 +02:00
Jay 3cf6ad7203 chore(release): v1 alpha 1 2022-05-31 21:14:45 +02:00
Jay d82ea47dd3 fix(Tests): updating regex to allow for pre-releases 2022-05-31 21:12:55 +02:00
Jay e90ced4957 docs: upgrade guide and changelog updated 2022-05-29 16:57:07 +02:00
Jay afe702bccd docs: updated code of coduct, contributing gude and license for latest release version 2022-05-28 23:06:24 +02:00
Jay 9840656c59 docs: updated contributing guide to no longer contain the release section as this is not needed 2022-05-28 17:51:14 +02:00
Jay f5d4d688c1 docs: removed cookbook as this is mostly irrelevant 2022-05-28 17:46:22 +02:00
Jay 8c307299cb Update base with master (#4756)
* docs: updated code of conduct to the lates version of the contributors covenant

* docs: fixed markdown issues in changelog

* docs: updated contributors guide

* docs: fixed linting errors in docs
2022-05-28 17:25:33 +02:00
Jay c714cffa6c Update base with master (#4755)
* docs: updated code of conduct to the lates version of the contributors covenant

* docs: fixed markdown issues in changelog

* docs: updated contributors guide

* docs: fixed linting errors in docs
2022-05-28 17:25:06 +02:00
Jay 12103f8208 chore: adjusted CI to run on any current and future version branches 2022-05-28 12:09:21 +02:00
João Gabriel Quaresma 1504792765 Fixing content-type header repeated (#4745)
Co-authored-by: Jay <jasonsaayman@gmail.com>
2022-05-28 11:52:50 +02:00
Victor Augusto a11f9501b8 Fix/4737/timeout error message for http (#4738)
* Fixing timeoutErrorMessage in http calls

When timeoutErrorMessage was set this did not change anything in the error message, with this change the error message will be the configured message

* Testing timeoutErrorMessage in http calls

When timeoutErrorMessage was set this did not change anything in the error message, with this change the error message will be the configured message

Co-authored-by: Jay <jasonsaayman@gmail.com>
2022-05-28 11:46:33 +02:00