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

Merge pull request #317 from nickuraltsev/urlsearchparams

Adding support for URLSearchParams
This commit is contained in:
Matt Zabriskie
2016-05-24 20:40:25 -06:00
11 changed files with 100 additions and 20 deletions
+5 -1
View File
@@ -217,6 +217,7 @@ These are the available config options for making requests. Only the `url` is re
headers: {'X-Requested-With': 'XMLHttpRequest'},
// `params` are the URL parameters to be sent with the request
// Must be a plain object or a URLSearchParams object
params: {
ID: 12345
},
@@ -229,7 +230,10 @@ These are the available config options for making requests. Only the `url` is re
// `data` is the data to be sent as the request body
// Only applicable for request methods 'PUT', 'POST', and 'PATCH'
// When no `transformRequest` is set, must be a string, an ArrayBuffer, a hash, or a Stream
// When no `transformRequest` is set, must be of one of the following types:
// - string, plain object, ArrayBuffer, ArrayBufferView, URLSearchParams
// - Browser only: FormData, File, Blob
// - Node only: Stream
data: {
firstName: 'Fred'
},