zkt-fetch-retry

2.0.0 • Public • Published

zkt-fetch

wrapper of zkt-fetch to provide retry feature

Install

npm i --save zkt-fetch-retry

Usage

replace your require('zkt-fetch') with require('zkt-fetch-retry')

const fetch = require('zkt-fetch-retry');
fetch(url, {
    retry: 3,
    retryDelay: 1000
}).then(...).catch(...);

options

  • retry retry times, default to 3

  • retryDelay wait time in ms between retries, default to 1000

Package Sidebar

Install

npm i zkt-fetch-retry

Weekly Downloads

0

Version

2.0.0

License

MIT

Unpacked Size

4.26 kB

Total Files

5

Last publish

Collaborators

  • longbill