{"library":"mock-fetch-api","type":"library","category":null,"description":"A lightweight library (v1.0.7, no recent releases) for mocking HTTP requests and responses using the fetch API or isomorphic-fetch in unit tests. It provides a simple chainable API: when().withExpectedHeader().otherwiseRespondWith().respondWith(), plus failNextCall() for network errors. Compared to fetch-mock, it is less active and feature-limited but easier to read.","language":"javascript","status":"active","version":"1.0.7","tags":["javascript","mock-fetch-api","fetch","fetchAPI","fetch API","mock fetch API","mock-fetch","fetch-mock","unit testing"],"last_verified":"Sun Jun 07","install":[{"cmd":"npm install mock-fetch-api","imports":["import MockFetch from 'mock-fetch-api'","const MockFetch = require('mock-fetch-api')","global.fetch = MockFetch.fetch"]},{"cmd":"yarn add mock-fetch-api","imports":[]},{"cmd":"pnpm add mock-fetch-api","imports":[]}],"homepage":"https://github.com/Larney11/mock-fetch-api#readme","github":"https://github.com/Larney11/mock-fetch-api","docs":null,"changelog":null,"pypi":null,"npm":"mock-fetch-api","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":null}