JSPM

@polkadot/x-fetch

8.0.6-18
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 139757
  • Score
    100M100P100Q169759F
  • License Apache-2.0

A cross-environment fetch replacement

Package Exports

  • @polkadot/x-fetch
  • @polkadot/x-fetch/README.md
  • @polkadot/x-fetch/browser
  • @polkadot/x-fetch/browser.d.ts
  • @polkadot/x-fetch/index.d.ts
  • @polkadot/x-fetch/node
  • @polkadot/x-fetch/node.d.ts
  • @polkadot/x-fetch/package.json
  • @polkadot/x-fetch/packageInfo
  • @polkadot/x-fetch/packageInfo.d.ts
  • @polkadot/x-fetch/react-native
  • @polkadot/x-fetch/react-native.d.ts
  • @polkadot/x-fetch/shim
  • @polkadot/x-fetch/shim.d.ts

Readme

@polkadot/x-fetch

A cross-environment fetch.

Install it via yarn add @polkadot/x-fetch

import { fetch } from '@polkadot/x-fetch';

...
const response = await fetch('https://example.com/something.json');
const json = await response.json();