Releases: jonbern/fetch-retry
TypeScript type definition
Adds TypeScript type definition file to improve tooling and developer experience for devs using TypeScript.
Big thanks to @fzembow for contributing a pull request for this feature!
Added flexibility with `retryDelay` and `onRetry` as functions
The new version adds support for specifying retryDelay
and onRetry
as functions, while staying backwards compatible.
This makes the library more flexible, and adds the possibility for users to implement exponential back-off instead of using a static retry interval. It also allows users to add custom logic on when to retry requests, or perform additional actions before a retry (for instance logging on retry attempts).
Many thanks to @thomsbg for making this release possible by contributing pull requests.
2.0.0
Using global fetch variable and promise polyfill
This version uses the global fetch
variable from isomorphic fetch, and the global promise polyfill from es6-promise
.
Added functionality to retry on configurable HTTP status codes.
1.2.0 Removes commented out code
Issue in readme
Updates README and fixes error