refresh-fetch
JSON →A wrapper around the fetch API that automatically handles authentication token refreshing. Current stable version is 0.9.0. It intercepts fetch responses, detects token expiry via a configurable `shouldRefreshToken` callback, performs token refresh via a `refreshToken` function, and retries the original request. Unlike manual token management, refresh-fetch abstracts the retry logic and ensures concurrent requests are serialized during token refresh. Requires ES6 Promise and fetch. Suitable for single-page apps using bearer tokens with expiry.
Traffic · last 30 days stale · no recent hits
total hits 20
actors 4 distinct systems
last hit 17d ago AhrefsBot
top countries 🇸🇬 Singapore · 🇺🇸 United States · VN · 🇨🇦 Canada · 🇩🇪 Germany