Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@fetch-impl/cross-fetch

JacobLinCool2kMIT1.0.0TypeScript support: included

User Configurable Fetch Implementation. cross-fetch adapter.

fetch, cross-fetch

readme

@fetch-impl/cross-fetch

User Configurable Fetch Implementation. cross-fetch adapter.

Usage

import { useCrossFetch } from "@fetch-impl/cross-fetch";
import fetch from "@fetch-impl/fetcher";

// configure fetch to use cross-fetch
useCrossFetch();

// use fetch as usual
fetch("https://example.com").then(async (res) => {
    console.log(res.status, await res.text());
});