silverwolf-x's picture
download
raw
432 Bytes
import { withRequest as withRequestContext } from './context'
import { interceptFetch, reader } from './fetch'
export function interceptTestApis(): () => void {
return interceptFetch(global.fetch)
}
export function wrapRequestHandler<T, TRequest extends Request>(
handler: (req: TRequest, fn: () => T) => T
): (req: TRequest, fn: () => T) => T {
return (req, fn) => withRequestContext(req, reader, () => handler(req, fn))
}

Xet Storage Details

Size:
432 Bytes
·
Xet hash:
33f446183c8d1123188cdcdf4383aee9309832e52baf7d526512a139ae7ac577

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.