mock-requests

JSON →
library 1.4.3 ·javascript
verified Jun 7, 2026

Mocks XMLHttpRequest and fetch requests with static or dynamic responses without changing source code. Current stable version 1.4.3. Release cadence appears low (latest 2022). Differentiators: no source code modification needed, supports both XHR and fetch, dynamic responses based on payload/query parameters, delay simulation, and Webpack plugin for production-like mocking. Unlike alternatives like fetch-mock or nock, it intercepts at the browser level and works with both APIs seamlessly.