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

Function layerConfig

packages/platform/node/src/NodeHttpServer.ts:466–478  ·  view source on GitHub ↗
(
  evaluate: LazyArg<Http.Server>,
  options: Config.Wrap<Options>
)

Source from the content-addressed store, hash-verified

464 * @since 4.0.0
465 */
466export const layerConfig = (
467 evaluate: LazyArg<Http.Server>,
468 options: Config.Wrap<Options>
469): Layer.Layer<
470 HttpServer.HttpServer | NodeServices.NodeServices | HttpPlatform.HttpPlatform | Etag.Generator,
471 ServeError | Config.ConfigError
472> =>
473 Layer.mergeAll(
474 Layer.effect(HttpServer.HttpServer)(
475 Effect.flatMap(Config.unwrap(options), (options) => make(evaluate, options))
476 ),
477 layerHttpServices
478 )
479
480/**
481 * Provides a test HTTP server listening on an ephemeral port together with a

Callers

nothing calls this directly

Calls 1

makeFunction · 0.70

Tested by

no test coverage detected