Since the announcement of request going into “deprecated mode” (full details in #3142) I’d like to collect a list of alternative libraries to use. Please comment below and I’ll update this table. This post will give you the alternative libraries to request module.
As you can see currently on npm “request has been deprecated“
In no particular order 😉here is the alternative libraries list:
node-fetch
Bundle Size 0.4kb
API Style promise / stream
Summary: A light-weight module that brings window.fetch to Node.js
bent
Bundle Size 1kb
API Style fp / promise / stream
Summary: Functional HTTP client w/ async/await
got
Bundle Size 48.4kb
API Style promise / stream
Summary: Simplified HTTP requests
make-fetch-happen
Bundle Size 442kb
API Style promise / stream
Summary: make-fetch-happen is a Node.js library that wraps node-fetch-npm with additional features node-fetch doesn’t intend to include, including HTTP Cache support, request pooling, proxies, retries, and more!
axios
Bundle Size 11.9kb
API Style promise / stream
Summary: Promise based HTTP client for the browser and node.js
unfetch
Bundle Size 1kb
API Style promise / stream
Summary: Tiny 500b fetch “barely-polyfill”
superagent
Bundle Size 18kb
API Style chaining / stream
Summary: Small progressive client-side HTTP request library, and Node.js module with the same API, sporting many high-level HTTP client features
tiny-json-http
Bundle Size 22kb
API Style promise
Summary: Minimalist HTTP client for GET and POSTing JSON payloads
That’s it for now.
If you liked this article, then please subscribe to my YouTube Channel for video tutorials.