MCPcopy Create free account
hub / github.com/Effect-TS/effect / arrayBuffer

Method arrayBuffer

packages/ui/native/src/NativeHttpClient.ts:429–439  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

427 }
428
429 get arrayBuffer(): Effect.Effect<
430 ArrayBuffer,
431 HttpClientError.HttpClientError
432 > {
433 return Effect.flatMap(this.loaded, (body) => {
434 const bytes = this.bytes(body)
435 return bytes instanceof Uint8Array
436 ? Effect.succeed(bytes.buffer as ArrayBuffer)
437 : Effect.fail(bytes)
438 })
439 }
440
441 get json(): Effect.Effect<Schema.Json, HttpClientError.HttpClientError> {
442 return Effect.flatMap(this.text, (text) =>

Callers 5

formDataBodyFunction · 0.95
answerFunction · 0.45
generate-emoji.mjsFile · 0.45

Calls 3

bytesMethod · 0.95
failMethod · 0.65
succeedMethod · 0.45

Tested by

no test coverage detected