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

Function use

packages/effect/src/unstable/http/HttpRouter.ts:478–480  ·  view source on GitHub ↗
(
  f: (router: HttpRouter) => Effect.Effect<A, E, R>
)

Source from the content-addressed store, hash-verified

476 * @since 4.0.0
477 */
478export const use = <A, E, R>(
479 f: (router: HttpRouter) => Effect.Effect<A, E, R>
480): Layer.Layer<never, E, HttpRouter | Exclude<R, Scope.Scope>> => Layer.effectDiscard(Effect.flatMap(HttpRouter, f))
481
482/**
483 * Create a layer that adds a single route to the HTTP router.

Callers 2

addFunction · 0.70
effect.tsFile · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected