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

Adding documentation for httpAgent and httpsAgent in README

This commit is contained in:
Rubén Norte
2016-07-25 00:07:44 +02:00
parent 4c790d5a7a
commit f504dbaba8
+7 -1
View File
@@ -289,7 +289,13 @@ These are the available config options for making requests. Only the `url` is re
// `maxRedirects` defines the maximum number of redirects to follow in node.js.
// If set to 0, no redirects will be followed.
maxRedirects: 5 // default
maxRedirects: 5, // default
// `httpAgent` and `httpsAgent` define a custom agent to be used when performing http
// and https requests, respectively, in node.js. This allows to configure options like
// `keepAlive` that are not enabled by default.
httpAgent: new http.Agent({ keepAlive: true }),
httpsAgent: new https.Agent({ keepAlive: true })
}
```