JSON Fetch
JSON →json-fetch is a lightweight wrapper around the ES6 fetch API that simplifies interacting with JSON APIs. It automatically serializes request bodies to JSON and sets appropriate Content-Type headers, parses responses as JSON when Content-Type is application/json, includes credentials by default, and supports configurable retry logic via the promise-retry library. Current stable version: 9.0.10. Release cadence is irregular. Key differentiators: built-in retry strategies for 5xx errors and network errors, request/response lifecycle callbacks, TypeScript type declarations (requires DOM lib), and a simple API that reduces boilerplate for JSON API calls. Supports Node.js >=12.
Traffic · last 30 days stale · no recent hits
top countries 🇺🇸 United States · 🇸🇬 Singapore · 🇳🇴 Norway · 🇮🇩 Indonesia · 🇮🇹 Italy