2
0
mirror of https://github.com/tenrok/axios.git synced 2026-06-23 20:40:40 +03:00

Fix markup for note in README (#4825)

Co-authored-by: Jay <jasonsaayman@gmail.com>
This commit is contained in:
Grégoire Pineau
2022-09-14 21:32:23 +02:00
committed by GitHub
parent 242c1d9782
commit dd5ba02254
+4 -4
View File
@@ -170,7 +170,7 @@ async function getUser() {
} }
``` ```
> **NOTE:** `async/await` is part of ECMAScript 2017 and is not supported in Internet > **Note** `async/await` is part of ECMAScript 2017 and is not supported in Internet
> Explorer and older browsers, so use with caution. > Explorer and older browsers, so use with caution.
Performing a `POST` request Performing a `POST` request
@@ -819,7 +819,7 @@ axios.get('/user/12345', {
cancel(); cancel();
``` ```
> Note: you can cancel several requests with the same cancel token/abort controller. > **Note:** you can cancel several requests with the same cancel token/abort controller.
> If a cancellation token is already cancelled at the moment of starting an Axios request, then the request is cancelled immediately, without any attempts to make a real request. > If a cancellation token is already cancelled at the moment of starting an Axios request, then the request is cancelled immediately, without any attempts to make a real request.
> During the transition period, you can use both cancellation APIs, even for the same request: > During the transition period, you can use both cancellation APIs, even for the same request:
@@ -872,7 +872,7 @@ axios.post('https://something.com/', querystring.stringify({ foo: 'bar' }));
You can also use the [`qs`](https://github.com/ljharb/qs) library. You can also use the [`qs`](https://github.com/ljharb/qs) library.
> NOTE: > **Note**
> The `qs` library is preferable if you need to stringify nested objects, as the `querystring` method has [known issues](https://github.com/nodejs/node-v0.x-archive/issues/1665) with that use case. > The `qs` library is preferable if you need to stringify nested objects, as the `querystring` method has [known issues](https://github.com/nodejs/node-v0.x-archive/issues/1665) with that use case.
### 🆕 Automatic serialization to URLSearchParams ### 🆕 Automatic serialization to URLSearchParams
@@ -989,7 +989,7 @@ Axios FormData serializer supports some special endings to perform the following
- `{}` - serialize the value with JSON.stringify - `{}` - serialize the value with JSON.stringify
- `[]` - unwrap the array-like object as separate fields with the same key - `[]` - unwrap the array-like object as separate fields with the same key
> NOTE: > **Note**
> unwrap/expand operation will be used by default on arrays and FileList objects > unwrap/expand operation will be used by default on arrays and FileList objects
FormData serializer supports additional options via `config.formSerializer: object` property to handle rare cases: FormData serializer supports additional options via `config.formSerializer: object` property to handle rare cases: