JSPM

  • Created
  • Published
  • Downloads 22
  • Score
    100M100P100Q67009F
  • License MIT

Enhanced-fetch is a utility library that enriches the built-in fetch API with features such as support for response types, timeouts, and destroyable requests.

Package Exports

  • @jswork/enhanced-fetch
  • @jswork/enhanced-fetch/dist/index.esm.js
  • @jswork/enhanced-fetch/dist/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@jswork/enhanced-fetch) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

enhanced-fetch

Enhanced-fetch is a utility library that enriches the built-in fetch API with features such as support for response types, timeouts, and destroyable requests.

version license size download

installation

npm install @jswork/enhanced-fetch

usage

snapshot
import enhancedFetch from '@jswork/enhanced-fetch';

const opts = {
  debug: true,
  timeout: 1000,
  resposneType: 'json'
};

const res = await enhancedFetch('https://api.github.com/users/afeiship', opts);

license

Code released under the MIT license.