mirror of
https://github.com/tenrok/axios.git
synced 2026-06-14 18:42:33 +03:00
Updating README
This commit is contained in:
@@ -103,13 +103,15 @@ When using the alias methods `url`, `method`, and `data` properties don't need t
|
|||||||
|
|
||||||
### Config
|
### Config
|
||||||
|
|
||||||
|
This is the available config options for making requests. Only the `url` is required. Requests will default to `GET` if not specified.
|
||||||
|
|
||||||
```js
|
```js
|
||||||
{
|
{
|
||||||
// `url` is the server URL that will be used for the request
|
// `url` is the server URL that will be used for the request
|
||||||
url: '/user',
|
url: '/user',
|
||||||
|
|
||||||
// `method` is the request method to be used when making the request
|
// `method` is the request method to be used when making the request
|
||||||
method: 'get',
|
method: 'get', // default
|
||||||
|
|
||||||
// `transformRequest` allows changes to the request data before it is sent to the server
|
// `transformRequest` allows changes to the request data before it is sent to the server
|
||||||
// This is only applicable for request methods 'PUT', 'POST', and 'PATCH'
|
// This is only applicable for request methods 'PUT', 'POST', and 'PATCH'
|
||||||
|
|||||||
Reference in New Issue
Block a user