MCPcopy Index your code
hub / github.com/solidjs/solid-start / createFetchEvent

Function createFetchEvent

packages/start/src/server/fetchEvent.ts:7–15  ·  view source on GitHub ↗
(event: H3Event)

Source from the content-addressed store, hash-verified

5const FETCH_EVENT_CONTEXT = "solidFetchEvent";
6
7export function createFetchEvent(event: H3Event): FetchEvent {
8 return {
9 request: event.req,
10 response: event.res,
11 clientAddress: getRequestIP(event),
12 locals: {},
13 nativeEvent: event,
14 };
15}
16
17export function getFetchEvent(h3Event: H3Event): FetchEvent {
18 if (!h3Event.context[FETCH_EVENT_CONTEXT]) {

Callers 2

fetchEvent.spec.tsFile · 0.90
getFetchEventFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected