castToResponse
Overview
castToResponse
(event, responseLike, reactRenderOptions?): `Promise<Response>`
Throws
Parameters
Name | Type |
---|---|
event | IsomorphicFetchEvent<any, any, any> |
responseLike | ResponseLike |
reactRenderOptions? | ReactRendererOptions |
Returns
Promise<Response>
Defined in
http/functions/castToResponse.ts:40
Infers the appropriate Response constructor for the given
ResponseLike
body.While the
RequestRouter
automatically converts returned values viacastToResponse
.