Sha256: f762779b3e31e288e757bfbc333b181fa97e921be5cfe27a24d0bf1d318bd355
Contents?: true
Size: 667 Bytes
Versions: 26
Compression:
Stored size: 667 Bytes
Contents
import type { StrictResponse } from './HttpResponse' /** * Performs the intercepted request as-is. * * This stops request handler lookup so no other handlers * can affect this request past this point. * Unlike `bypass()`, this will not trigger an additional request. * * @example * http.get('/resource', () => { * return passthrough() * }) * * @see {@link https://mswjs.io/docs/api/passthrough `passthrough()` API reference} */ export function passthrough(): StrictResponse<any> { return new Response(null, { status: 302, statusText: 'Passthrough', headers: { 'x-msw-intention': 'passthrough', }, }) as StrictResponse<any> }
Version data entries
26 entries across 26 versions & 1 rubygems