MCPcopy Index your code
hub / github.com/Effect-TS/effect / uint8Array

Function uint8Array

packages/platform/src/internal/httpServerResponse.ts:120–132  ·  view source on GitHub ↗
(
  body: Uint8Array,
  options?: ServerResponse.Options.WithContentType
)

Source from the content-addressed store, hash-verified

118
119/** @internal */
120export const uint8Array = (
121 body: Uint8Array,
122 options?: ServerResponse.Options.WithContentType
123): ServerResponse.HttpServerResponse => {
124 const headers = options?.headers ? Headers.fromInput(options.headers) : Headers.empty
125 return new ServerResponseImpl(
126 options?.status ?? 200,
127 options?.statusText,
128 headers,
129 options?.cookies ?? Cookies.empty,
130 internalBody.uint8Array(body, getContentType(options, headers))
131 )
132}
133
134/** @internal */
135export const text = (

Callers

nothing calls this directly

Calls 1

getContentTypeFunction · 0.85

Tested by

no test coverage detected