From 787de1eba3cb0dde7beb32cc1b0584a949f44895 Mon Sep 17 00:00:00 2001 From: Marshmalow212 Date: Wed, 27 Nov 2024 14:09:39 +0600 Subject: [PATCH] Added axios integrations entry to README file (#121) --- README.md | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/README.md b/README.md index fa3cc50..de8bde7 100644 --- a/README.md +++ b/README.md @@ -159,6 +159,32 @@ sget.concat({ // handle the response }) ``` +### [axios](https://github.com/axios/axios) + +```js +axios.get( + 'http://localhost:9200', + { + httpsAgent: new HttpsProxyAgent({ + keepAlive: true, + keepAliveMsecs: 1000, + maxSockets: 256, + maxFreeSockets: 256, + proxy: 'http://localhost:8080' + }) + } +) +.then( + res => console.log(res.data) +) +.catch( + e => console.log(e) +) +.finally( + () => console.log('Request through proxy completed') + +); +``` ## License