Response Iterator
JSON →response-iterator is a utility library designed to normalize various HTTP response bodies into a consistent asynchronous iterator interface, compatible across both browser and Node.js environments. It currently stands at stable version 1.0.10 and is regularly maintained. The library abstracts away the differences in how `Response` objects (or similar constructs) are handled by different HTTP clients such as standard `fetch`, `node-fetch`, `cross-fetch`, `axios`, `got`, and `undici`. Its key differentiator is providing a simple `for await...of` loop mechanism to consume streamed data chunks, making it easier to process large responses efficiently without loading the entire body into memory, irrespective of the underlying fetch implementation. It significantly simplifies working with streaming data by adhering to the `Symbol.asyncIterator` protocol.
Traffic · last 30 days ↑14% vs prev 7d
top countries 🇺🇸 United States · 🇨🇦 Canada · 🇪🇸 Spain · 🇩🇪 Germany · 🇫🇷 France